ALLInterview.com :: Home Page            
 Advertise your Business Here     
Browse  |   Placement Papers  |   Company  |   Code Snippets  |   Certifications  |   Visa Questions
Post Question  |   Post Answer  |   My Panel  |   Search  |   Articles  |   Topics  |   ERRORS new
   Refer this Site  Refer This Site to Your Friends  Site Map  Bookmark this Site  Set it as your HomePage  Contact Us     Login  |  Sign Up                      
Google
   
 
Categories >> Software >> Programming Languages >> C
 
 


 

 
 C interview questions  C Interview Questions (2254)
 C++ interview questions  C++ Interview Questions (1111)
 VC++ interview questions  VC++ Interview Questions (342)
 Delphi interview questions  Delphi Interview Questions (510)
 Programming Languages AllOther interview questions  Programming Languages AllOther Interview Questions (646)
Question
what is the difference between NULL & NUL keywords in C?
 Question Submitted By :: C
I also faced this Question!!     Answer Posted By  
 
Answer
# 1
NULL is a macro defined in for the null pointer.
NUL is the name of the first character in the ASCII
character set. It corresponds to a zero value. There's no
standard macro NUL in C, but some people like to define it.
The digit 0 corresponds to a value of 80, decimal.
Don't confuse the digit 0 with the value of '' (NUL)!
NULL can be defined as ((void*)0), NUL as ''.
 
Is This Answer Correct ?    18 Yes 3 No
Shriku322
 
Answer
# 2
NULL is a macro defined in <stddef.h> for the null pointer.
<br>NUL is the name of the first character in the ASCII
character set. It corresponds to a zero value. There?s no
<br>standard macro NUL in C, but some people like to define
it. <br>The digit 0 corresponds to a value of 80, decimal.
Don?t confuse the digit 0 with the value of ?? (NUL)!
<br>NULL can be defined as ((void*)0), NUL as ??. <br>

? NewInterviewQuestions.com
 
Is This Answer Correct ?    16 Yes 5 No
Abhijit
 
 
 
Answer
# 3
Neither NULL nor NUL is a keyword in C.
[International Standard ISO/IEC 9899:1999, Programming
Languages -- C, Section 6.4.1 Keywords]

That said, Abhijit did a good job explaining them.
 
Is This Answer Correct ?    5 Yes 9 No
Bryan Olson
 

 
 
 
Other C Interview Questions
 
  Question Asked @ Answers
 
write a program which counts a product of array elements lower than 10.   1
what is the defrenece between structure and union Aloha-Technology 5
while running a program, i got the msg that press return key to exit.what that mean in C as there are no such options as far i know. Tcs 1
Write a program to display the no of bit difference between any 2 given numbers eg: Num1 will 12->1100 Num2 will 7->0111 the difference in bits are 2.   4
Write a program to find given number is even or odd without using any control statement.   2
Find string palindrome 10marks Honeywell 5
write a program to swap two numbers without using temporary variable?   3
write a program to print sum of each row of a 2D array.   3
code for concatination of 2 strings with out using library functions?   3
what is volatile in c language? TCS 9
write a program to swap two variables a=5 , b= 10 without using third variable   5
What is C++   4
 
For more C Interview Questions Click Here 
 
 
 
 
 


   
Copyright Policy  |  Terms of Service  |  Articles  |  Site Map  |  RSS Site Map  |  Contact Us
   
Copyright 2013  ALLInterview.com.  All Rights Reserved.

ALLInterview.com   ::  KalAajKal.com