Hi,
I had a cool experience... so I thought I'll post it here
This year C++ has become a part of my computer syllabus at school... So we have a teacher who teaches it. I had some previous knowledge of C++ - though I'm not at all good at it currently.
None of my friends have any idea about this language. So when she started teaching I could feel that she was really missing a lot of basic stuffs... bah.. that was a bad time - her class is really boring also. She used to make a lot of mistakes... but I don't remeber most of them.. but I remember a serious one.. read on
So after a few months, it was exams - ie the first exam on C++.
I felt the paper was quite easy... but there was one question that appeared pretty normal or needed no thinking on my first look (plz, i'm a newbie)... But after a while of writing, I looked at the question again.. OOPS! I had made a serious mistake!
I rewrote the answer. So, after a few weeks, the papers were corrected and I was eager to see how much I got for that question because none of my friends wrote correctly (note that they are super newbies and pretty poor because of this teacher's training )
To my shock, I didn't get anything for that question... the teacher marked it completely wrong! and all my classmates who wrote it wrong got full marks for the question.
So, I went to the teacher and argued with her for sometime (maan, I don't know what I said)... atlast she agreed with me - coz I said to her that I tried it on the computer and my answer was correct... So it ended up with me and all others getting full marks... LOL.. I wz the only person who got it correct and all of us got full marks... So u want to see what the question is ??

Question

Convert the follow to a switch statement
Code:
  if(dir == 'E')
       est++;
     if(dir == 'W')
       wst++;
     if(dir== 'N')
       nth++;
     if(dir == 'S')
       sth++;
     else
       unk++;
Answer which she thinks is correct and what all the others also wrote
Code:
switch(dir)
     {
       case 'E' : est++; break;
       case 'W' : wst++; break;
       case 'N': nth++; break;
       case 'S': sth++; break;
       default : unk++;
     }
My Answer
Code:
switch(dir)
      {
        case 'E' : est++; unk++; break;
        case 'W' : wst++; unk++; break;
        case 'N': nth++; unk++; break;
        case 'S': sth++; break;
        default : unk++;
      }
It was she who gave one another question and a strange output... that made me go very confused and she won't explain why that output was happening... actually the question was this(I posted it here a few months ago the time she gave it)
One more year is left with her! I don't know how much I'm going to suffer. Did anyone have any experiences like this?
(sorry about making the title ironic)