Hello everone i need to help about c# code its not working

When you ask a question, don’t forget to include a link to the exercise or project you’re dealing with!

If you want to have the best chances of getting a useful answer quickly, make sure you follow our guidelines about how to ask a good question. That way you’ll be helping everyone – helping people to answer your question and helping others who are stuck to find the question and answer! :slight_smile:

https://www.codecademy.com/workspaces/62978112cb97897a2c757ce0

this is my code and its not working am just starting c# codding

if (sonuc > 80 && sonuc < 100) ; 
//                             ^
            {
             Console.WriteLine("Not Değeriniz :+A");
            }

            else if (sonuc > 60 && 80 < sonuc) ;
//                                             ^
            {
             Console.WriteLine("Not Değeriniz : A");
            }

            else if (sonuc > 60 && sonuc < 40) ;
//                                             ^
            {
             Console.WriteLine("Not Değeriniz : B");
            }

            else
            {
             Console.WriteLine("Not Değeriniz : F");
            }

There should not be a semicolon between the if or else if conditions, and the code block to be executed when those conditions evaluate to truthy.

thanks bro am just started watching training videos about c# i was writing same codes from video

i think my mind is mixed and i didt see ( ; ) this

it is workin now thanks for feedback , probaply i wil ask agan million question :wink:

1 Like