I'm writing a code that output an output when using porlandc++ but when using eclipse it doesn't, a "Nothing to build for Help" message appears in the console. my file's name is "Help". Even I've tried to debug it putting a breaking point on the first printf function in the code but the debugger always jump to the end of the code?
I'm new with eclipse so I'll be grateful if you help
/*
* help.c
*
* Created on: ٠٨/٠١/٢٠١٤
* Author: Salahuddin
*/
#include <stdio.h>
int get_int(void);
double get_double(void);
int main(void)
{
int a;
double b;
printf("Enter an integer : ");
a=get_int();
printf("The integer you entered is : %i",a);
printf("Enter a double : ");
b=get_double();
printf("The double you entered is : %lf",b);
return 0;
}
int get_int(void)
{
int result;
printf(">");
while(scanf("%i",&result)!=1)
{
while(getchar()!='\n')
;
printf(">");
}
return result;
}
double get_double(void)
{
double result;
printf(">");
while(scanf("%lf",&result)!=1)
{
while(getchar()!='\n')
;
printf(">");
}
return result;
}
By the way, when I started debugging, many threads appeared not just one, and when trying to stop them, all of them stop except the last one, don't know why?
as I said I'm new with eclipse trying to learn how to use it in debugging instead of the porland c++
thanks a lot