Programming for Idiots (C#) - Take 2

02/03/2011 18:49 PuN|SheR#76
Quote:
Originally Posted by denominator View Post
I have to agree with an earlier post about lesson four Type Conversion I got kind of confused at the end but that`s because my math sucks lol. I get the concept of it all though within reason :) I shall continue reading and yes I am actually learning :D

Ok so I did it this way is it wrong (obviously not that much because it worked)

Code:
namespace ConsoleApplication1
{
    class Program
    {
        static void Main(string[] args)
        {
            int age = int.Parse(Console.ReadLine());
            if (age < 16)
            {
                Console.WriteLine("You can`t enter");
            }
            else if ((age >= 16) && (age <= 18))
            {
                Console.WriteLine("You can come in but can`t drink");
            }
            else if (age >= 19)
            {
                Console.WriteLine("You can drink as well");
            }
        }
    }
}
Oh and THANK YOU! I definately recommend this to anybody that wants to learn and understand C# because you have explained it very simply and this is the kind of thing I can learn from :D It`s similar to how I have learnt php/html/javascript
Its good for beginning , but you could help the one who use it with asking him the question how old is he Like this way:

Code:
namespace ConsoleApplication1
{
    class Program
    {
        static void Main(string[] args)
        {
[B][I]Console.Write("How Old Are You ? Answer : ");[/I][/B]
            int age = int.Parse(Console.ReadLine());
            if (age < 16)
            {
                Console.WriteLine("You can`t enter");
            }
            else if ((age >= 16) && (age <= 18))
            {
                Console.WriteLine("You can come in but can`t drink");
            }
            else if (age >= 19)
            {
                Console.WriteLine("You can drink as well");
            }
        }
    }
}
But anyway,good enough :)
02/04/2011 02:15 QuakeZ#77
thank you for making these :D They are so easy to understand so please keep making them if u ever find the time to do so! I really appreciate it!
02/07/2011 19:37 §hift#78
Quote:
Originally Posted by PuN|SheR View Post
You mean Console.Readline(); ?
No?
02/08/2011 13:08 vecko12#79
Quote:
Originally Posted by PuN|SheR View Post
You mean Console.Readline(); ?
Console.ReadKey();
02/13/2011 21:30 WarpGeorge#80
Buddy, the Lesson II from Unit Two it's not working (link down). Could you please take your time and re-upload it?
02/15/2011 17:51 donady#81
Quote:
Originally Posted by InfamousNoone View Post
Once again, in a more serious manor I'm going to take a crack at this. Since this time I'm not doing it via videos, revisions can be made an re-uploaded so if any problems are found, please let me know and I'll try to get them fixed as soon as possible. Also, because I'm not doing them via videos, I don't intend for the units or "lessons" to be as rushed.

Feel free to email any questions to [Only registered and activated users can see links. Click Here To Register...]. Only material that needs revising should be posted on this thread. Please note, I couldn't care less about spelling, or grammatical content; as long as what is said is understandable. If you think something should be phrased another way, please consider this as a revision and worth posting.
For example: "In lesson 4's assignment, the result is wrong. It should be (...)"
Feel free to critique these works in any way, and also post this -- however, I'd appreciate if only constructive criticism is posted.

With that, thank you for your time and anyone who already knows this material who has decided to proof-read my work.

You should open these files with Microsoft Word.
Alternatives:
Microsoft Word Viewer: [Only registered and activated users can see links. Click Here To Register...]
Google Docs: [Only registered and activated users can see links. Click Here To Register...]
Open Office: [Only registered and activated users can see links. Click Here To Register...]


Getting Started: [Only registered and activated users can see links. Click Here To Register...]

Unit One - The Basics:


Unit Two - A Broader Horizon:


Unit Three - Frequently used classes:


Unit Four - GUI building:


Unit Five - Welcome to the dark-side (Pointer logic, PInvoke, Memory, etc.):


More to come soon...
No webpage was found for the web address: [Only registered and activated users can see links. Click Here To Register...]

(unit 2, lesson 2 = error file not found)
02/15/2011 19:31 Syst3m_W1z4rd#82
Quote:
Originally Posted by donady View Post
No webpage was found for the web address: [Only registered and activated users can see links. Click Here To Register...]

(unit 2, lesson 2 = error file not found)
Works fine for me.
02/24/2011 21:22 Basser#83
Still waiting for Unit 4 and perhaps even 5?
Or should I have lost hope already?
02/25/2011 16:53 DeathByMoogles#84
Last edited by InfamousNoone; 12-26-2010 at 13:33.

This are make me sad.
=/
02/25/2011 22:13 Syst3m_W1z4rd#85
I guess his just a little busy :)
03/06/2011 16:11 chickmagnet#86
unit 2 lesson 2 is no longer available reupload plz
03/13/2011 04:18 ImFlamedCOD#87
I got a copy of them all ill upload them in a couple of days once i return to my home.
03/21/2011 10:38 brokenarrow_vip#88
Quote:
Originally Posted by InfamousNoone View Post


Unit Three - Frequently used classes:


Unit Four - GUI building:


Unit Five - Welcome to the dark-side (Pointer logic, PInvoke, Memory, etc.):
WHERE ARE THOSE UNITS?

WHERE IS LESSON 2 ON UNIT 2?

should we report un-updated thread?
03/26/2011 08:37 C# Coder#89
unit 2 lesson 2 offline upload again plz
04/07/2011 08:05 spare2#90
Not to be completely technical, but the definition of scope should be defined somewhere between 2.1 and 2.2 if it isn't already, couldn't read lesson two of the second unit. (Link was down :()

Surprisingly, wikipedia's example is in C#:
The following example shows various scopes declared in the language C#:
Code:
[COLOR="Navy"]namespace[/COLOR] N
{                        [COLOR="SlateGray"]// namespace scope, merely groups identifiers[/COLOR]
   [COLOR="red"]class[/COLOR] C
   {                     [COLOR="SlateGray"]// class scope, defines/declares member variables and functions[/COLOR]
      [COLOR="navy"]void[/COLOR] f ([COLOR="Red"]bool[/COLOR] b)
      {                  [COLOR="SlateGray"]// outermost block (function) scope, contains executable statements[/COLOR]
         [COLOR="navy"]if[/COLOR] (b)
         {               [COLOR="SlateGray"]// inner block scope for conditionally executed statements
                          // (Note, both block scopes are unnamed.)[/COLOR]
           ...
         }
      }
   }
}