הפעם כתבתי אותה לבד... הנה התכנית עצמה:
#include <stdio.h>
void main()
{
char name, city;
int age;
printf("Please enter your name:");
name = getchar();
printf("Please enter your age:");
age = getchar();
printf("Please enter the city you live in:")
city = getchar();
printf("Your name is ")
putchar(name);
printf(", you are ")
putchar(age);
printf("years old and you live in ")
putchar(city);
getch();
}
והנה השגיאות שהמהדר מראה:
Error NONAME01.CPP 11: statement missing ;
Error NONAME01.CPP 13: Call of nonfunction
Error NONAME01.CPP 15: Call of nonfunction
Error NONAME01.CPP 17: Call of nonfunction
Error NONAME01.CPP 18: function 'getch' should have a prototype
Warning NONAME01.CPP 19: 'age' is assigned a value that is never used
Warning NONAME01.CPP 19: 'name' is assigned a value that is never used
תודה מראש לעוזרים...