Friday, May 25, 2007

Debugging Questions

Hi friends......just a small trivia......
mail ur answers to ssanthosh_13@yahoo.com

1.
#include
#include
void main()
{
int i=-2,j=-1,k;
k=i+++j;
j=i-+-j;
i=i+--j;
printf("%d%d%d",k,j,i);
}

a) -3-3-4 b)-2-2-5 c)-3-3-5 d)-2-3-4

2.
#include
#include
void main()
{
int i=-2,j=2,k=0,m;
clrscr();
m=++i||++j&&++k;
printf("%d%d%d%d",i,j,k,m);
getch();
}

a) -12111 b)-12001 c)-13111 d)-121010

3.
include
#include
#include
void main()
{
int a[5]={2,3,4,5,6},j;
clrscr();
printf("%d",(a+4)-(a+2));
getch();
}
a) 4 b) 2 c) 6 d) Error

4.
#include
#include
void swap(int* a,int* b);
void main()
{
int x=10,y=8;
swap(&x,&y);
printf("x==%d y==%d ",x,y);
}
void swap(int* a,int* b)
{
*a^=*b;
*b^=*a;
*a^=*b;
}
a) carbage value b) compile time error c) 8 10 d)run time error


5.
#include
#include
#include
void main()
{
int i=3,j=4;
clrscr();
if((i++&j++)||(--i||++j))
printf("Yes");
else
printf("No");
printf("%d%d",i,j);
getch();
}

a)yes 45 b)no 35 c)yes 35 d)no 36

6.
#include
#include
#define exp(x) x*x++
void main()
{
int i=3,j=2,k;
clrscr();
k=exp(i)*exp(j)+exp(i);
printf("%d %d",i,k);
getch();
}
a)4 52 b)5 52 c) 4 45 d)5 45

7.
#include
#include
#include
void main()
{
int i=3,j=2,k;
char c[5]={'3','2'};
clrscr();
j=atoi(c);
printf("%d %d %d %c %c",i--,+-i,j,c[0],c[3]);
getch();
}

a) 3 -2 3 3 0 b) 3 -3 32 3 c) 3-2 32 3 d) 3 -2 32 3 0

8.
#include
#include
void main()
{
int j=2;
char *c="2";
clrscr();
j=atoi(c);
j*2;
switch(j)
{
default:
printf("The Style ");
case 0:
printf("The lover ");
break;
case 1:
printf("The terror ");
break;
case 2:
printf("The fun ");
break;
case 3:
printf("The reformer");
}
getch();
}
a) The fun b)The style The lover c)The lover d)Error

9.
#include
#include
void main()
{
int a[5]={2,3,4,5,6},j;
clrscr();
j=*(a+4)/*(a+1);
printf("%d",j);
getch();
}
a) 3 b) 2 c) 4 d) Error

10.
Which of the following is not a c++ keyword?
a) atoll
b) volatile
c) bool
d) kbhit

Saturday, May 19, 2007

kodumai...kodumai...nnu kovilukku pona... anga oru kodumai thala virichu aaduthu...

Inspired by my friends, I thought of creating a blog for a lo.........ng time. Finally I too have started posting. Now coming to the matter....
After seeing my PQT mark, I was shocked. I found some 25 marks were missing and was confident of getting the marks. So after consulting my lecturer, I asked for the Xerox copy of my answer sheet. I got the xerox copy some 3 days before. As soon as I got the Xerox, I went to my math sir and confirmed that about 25 marks were missing. The bloody _______1, who corrected my paper has stopped awarding marks when he found that I was getting pass mark and gave zero to all the remaining questions. So my Sir advised me to go for revaluation. Afterwards I went to my college office for revaluation. The office staff said that I could not apply for revaluation after getting the Xerox and it must be applied along with Xerox. I was shocked and informed the matter to Math Dept. Some staff members asked me to go to the Controller of Examination, Anna University and try since they fought and got marks for students in similar cases. I went to the CoE and that _____2 started to shout at me and was talking like a P_______. Stimulated by my friends, I too had counter argument with him. After 15 minutes of 'kara sara vivadham' he said, “I will give u one chance. You get a letter from your college principal and I will consider your paper for revaluation along with revised valuation (Valuation for those who got less than 20 out of 80). My parents asked me to follow the matter. So I went to an important person in my college and asked the letter. That _____3, instead of supporting the student, talked for Anna University. She said,"Principalukku vera velai illaiya?" and refused to give the letter. She behaved as if I have asked their 'Uyir' from them. According to them I am one among the 2000 prisoners of this Jail. I don't know in what way they are going to be affected in sending/giving a letter for/to me. Even the HoD's and the staff members are not aware of this rule, then what for they are having it. The ______'s used to send circular for some ______ing purposes, but failed to inform this important message to students and talking like 'Ladu Langoties'. Not even 10% of the students are aware of this rule. One of my friends who was expecting a decent score got arrear in this paper. It is the second time happening to him. Similar thing happened him for FoC in I sem also. Considering his case mine is nothing. But thinking about the standard of valuation, I cannot digest. "Ella _____galum nallave irunthu tholaikattum" (I am not Bala).

Saturday, May 12, 2007

EXAMS "OVER"

My semester exams are over and I am free now. But let us see this over.

Ball 1: The first ball is DBMS Exam. The paper was somewhat easy. Though I just made defensive move.

Ball 2: The next ball is Computer Networks. All of us prepared the expected questions well. But the paper was such a way that each question contained four parts. Can be described as a “Full Toss Ball”. So again made a stroke.

Ball 3: This is Theory of Computation. On seeing the question paper I thought of scoring atleast 1 run. I tried to score first run. But when I started answering I couldn’t proceed. So came back to reach. But the ball hits the stumps.
Am I out or not?

Let us wait for the 3rd Umpire’s decision.

Ball 4: And this is the Micro Processor & Microcontrollers. Almost all have prepared only the architectures, pin diagrams and some other important questions which comprises to some 15 questions totally. Fortunately the paper was easy. It was similar to the one asked for the IT students last year. My friends Ramanujam, Mahesh etc. have written the answer for 8057 instead of 8037. But I did not attend the question. So no regreds.
I may score 1 run.

Ball 5: This one is Discrete Mathematics. The subject was the theory paper of maths. This is an easy one. So I have the possibility of scoring one more run.

Ball 6: The last one was PoM…PoM…(Principles of Management). As all know in this paper it is easy to score marks by simply blabbering. So many have started preparing only the day before the exam, that too in the evening. Before going to the exam Mahesh, Ramanujam and Raja taught each questions in the 5th unit. This paper is also an easy one. So may score another run.

Chae….

What is this life?
For each semester I am afraid of atleast one subject. Enna polappu (pizhaipu) idhu?

Thursday, May 10, 2007

Hello

Hi This is my first post....Inspired by my friend, babbu me too started blogging....I will write about my day today happenings......my expressions......my thinking and all those stuff in this blog......

This blog will tell about me. I am planning to post even some techinial articles. If u support it then it will be easy for me.


I may do some errors......Kindly adjust....


Love blogging.....