0

i am unable to compile my code due to GetInt function not recognized, i have tried all the solutions available, but none seems working for me... here is my code:

[EDIT: unrelated code removed]

// ask user for inputs
printf ("WHAT IS YOUR FIRST INTEGER: ");
int j = GetInt();
printf ("WHAT IS YOUR SECOND INTEGER: ");
int k = GetInt();
printf ("WHAT IS YOUR THIRD INTEGER: ");
int l = GetInt();

the response i get continually is : adder-1.c:11:13: error: implicit declaration of function 'GetInt' is invalid in C99 [-Werror,-Wimplicit-function-declaration] int j = GetInt();

kindly help

1 Answer 1

0

It appears that you're trying to use an older version of getint that has been retired.

Try get_int instead. Here's a link to the docs.

https://man.cs50.io/3/get_int

1
  • thank you, i wanna check the option now Commented Sep 2, 2020 at 0:30

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .