C Assignment - Day 1 [14-02-2000]

  • Uploaded by: deepti
  • 0
  • 0
  • November 2019
  • PDF

This document was uploaded by user and they confirmed that they have the permission to share it. If you are author or own the copyright of this book, please report to us by using this DMCA report form. Report DMCA


Overview

Download & View C Assignment - Day 1 [14-02-2000] as PDF for free.

More details

  • Words: 185
  • Pages: 1
C Assignment min.

Time duration 30

1 What is the difference between following code and Why is it used in the program? # include < prg1.c> # include “prg1.c” 2 What will be the out put of the following code? int r=0 , x=1, y=2 , z=3; If(x,y,z,r) printf( “Best of luck” ); else printf(“Welcome to CDAC”); 3 What will be the out put of the following code? int g=1, i=2,r=3,c; c = g++ || ++i && -- r ; printf( “%d,%d,%d,%d”, g,i,r,c ); 4.What will be the output of the following code? int i =2 ; i= i++*++i; printf(“%d”, i); 5.Read the following code and give the output ? int i, j; i=2;j=3; printf(“%d,%d,%d,%d”, i<2,i==2,i>2,i = -2); printf(“%d,%d”, j++, j--); 6. #define X 2+3; printf(“%d,%d”,X*2 , 2/X); What will be the output? 7. What will the following code do ? int x ; x +=2; printf(“%d”,x); 8. int x=2; while(x<14)printf(“%d,%d”,x++,++x); What will the following code do? 9. What does the code do? int x=2,y=3; printf(“%d”,y-x||--y); printf(“%d,%d”,x++,++y); 10.int x; x=4;x+=2;x-=2; printf(“%d”,--x - 2&&++x); What is the result of following code?

BEST OF LUCK FOR CDAC

Related Documents

C-lab-assignment-1
July 2020 8
C++ Assignment 1.docx
April 2020 16
Assignment C++
November 2019 13
C # Assignment
December 2019 24

More Documents from "api-3729297"