Author Topic: Forum Game: What's wrong with this code? - R2  (Read 1683 times)

C#: You have no proper capitilization for whatever reason, forgetting parenthesis, lots of stuff

fixed:
Code: [Select]
using System;
namespace hi
{
    static void Main()
    {
        Console.WriteLine("forumgame");
        Console.ReadKey();

        return;
    }
}

WINNER!

resetting..



I don't know a lick of Java.


For the java one, it's String[] args not String args[]

For the C one, you need a semicolon at the end of the return  statement


Hopefully with my basic knowledge from my advanced robotics class; I can solve the C one along with some optimization.
Added conio.h for _getch();

Code: [Select]
#include "stdio.h"
#include "conio.h"

int main() {
int a = 10;
int b = 20;
int c = a + b;
printf("%d\n", c);
_getch();
}


Hopefully with my basic knowledge from my advanced robotics class; I can solve the C one along with some optimization.
Added conio.h for _getch();

Code: [Select]
#include "stdio.h"
#include "conio.h"

int main() {
int a = 10;
int b = 20;
int c = a + b;
printf("%d\n", c);
_getch();
}
winner.