0
Error called undefined reference
I wrote a code for my studies and i need to use void function and if - else if . I wrote it but its not running. What should i do ? Anyone can help me . Thank you .
17 Respostas
+ 2
for ur point n3 i am not trying to compare values i am trying to set a condition if the average is equal to 0 and averge lees than 49 i want the program to out put ur grade is this .... and ur gpa is this ...
+ 2
Abdulaziz, that is what called comparison
+ 1
4 Thing I found wrong,
1. findLowest() function have different datatypes for its arguments in prototype and definition.
2.findLowest() function do not return anything.
3. Algorithm to calculate average is not defined.
4. Use == for comparison instead of just a single =.
+ 1
i solved the problem of the error.
now i am trying to solve the averge calculation fourmela problem .
+ 1
how to solve problem number 2 ?
+ 1
ohh ok i messd up š
+ 1
calculate the average first, then assign it to average variable...then do the if else stmt
+ 1
Resolved the error code.
Made few changes in FindLowest.
It would be more easier if you use for loop instead of if/else if in FindLowest function.
Hope help full...
https://code.sololearn.com/c4RdNkkedmNv/?ref=app
0
Sharing your code snippet can help find the error. Please do the same if you want your query solved.
0
I don't know how to share my code I'm new to this app
0
i need the program to calculate the averge of 4 lap marks using void functions .
0
Error called undefined reference is because of 1st point I mentioned.
0
that findlowest method is wrong
1.u dont return anything,it must return int
2.the average variable,it is undefined.u are not assigning it to any value, but yet u use it inside the if else stmt
3.inside the if else statement, use == or === for comparasion not =
0
thank you Naresh but my teacher asked for if / if else .
0
i solved all problems now and codde working fully
0
Thanks everyone