Please help me!

Please help me i am a C# student i need help,i am stuck at this lesson because i cant understand anything about this,i am gonna send the link now but i will send how is the program that it wants me to find the bugs and mistakes that it have.I have found the mistakes but i still dont understand something —>

‘’ https://www.codecademy.com/courses/learn-c-sharp/lessons/csharp-data-types-variables/exercises/handling-errors-csharp’’

this is the link,you can do a copy paste and see it,i dont understand the fact of why does the word myNum took the place of the word ‘‘is.yes’’.i know that is.yes is a bug so i deleted the is. and left behind it only yes but its wrong and the right answer was to replace it with myNum, i dont know why should i replace it with myNum.

I started C# 3 days ago so i still dont know much.

Thank you very much,’
Chuawei :innocent: :smiling_face_with_three_hearts: :crazy_face: :money_mouth_face: :open_hands:

2 Likes

Hi, if you paste the code and error messages more people can help directly (not everyone who knows c# does all the c# courses on CC) :slight_smile:

5 Likes

Thank you! But i actually cant copy paste it.

1 Like

Screenshot maybe?

1 Like

Oh thats a good idea actually. :innocent:

1 Like

use turbo c or turbo c++ if dosent understand and see video of technology gyan he showing how to make program and he telling abote basics also

1 Like

Well i guess still no hope for Help

For someone to help you, they are going to need to see your code in one way or another.
You can copy/paste your code, type it out, or post a screenshot.

If you choose either of the first two options, please post it formatted to preserve indentation. Simply press this button:

And then insert your code between the two rows of backticks:

2 Likes

here is your original code:

using System;

namespace BugSquasher
{
  class Program
  {
    static void Main(string[] args)
    {
      int number = 38498.3222;

      dinosaur = "Barney";

      double lock = 293.000;

      bool is.yes = true;

      string band = "The Low Anthem"

    }
  }
}

I will now give you what your code should look like with the errors fixed, you will be able to see what have changed for each of the variables and take the time to read the text you have on the left of your exercice page, they give the information for each variable on how to fix them or what could cause the problem.

using System;

namespace BugSquasher
{
  class Program
  {
    static void Main(string[] args)
    {
      double number = 38498.3222;

      string dinosaur = "Barney";

      double locked = 293.000;

      bool is_yes = true;

      string band = "The Low Anthem";

    }
  }
}

you can also click the yellow bar at the bottom of the exercice page to get a hint on what is the problem for each of them (they forgot to talk about lock, the problem with lock was that you cant use lock since its a keyword already being used in c#).
I hope this helps and ill come back to see if you have any other problem later ^^
P.S. the problem with is.yes is that it uses a point (.) inside of the variable wich is not allowed. You can only use underscores, letters and digits.

1 Like