study the code:
#include<stdio.h>
void main()
{
const int a=100;
int *p;
p=&a;
(*p)++;
printf("a=%dn(*p)=%dn",a,*p);
}
What is printed?
A)100,101 B)100,100 C)101,101 D)None of the
above
Answers were Sorted based on User's Feedback
Answer / jitendra kumar arya
(d),because n treat as a chracter.
ans is 100n ,101n
Is This Answer Correct ? | 1 Yes | 3 No |
Answer / venkataramani kumar.t.b.
The Answer is C) a=101 and (*p)=101.
Since the variable is not directly accessed and it
increments thru' the pointer, so the answer is valid
Is This Answer Correct ? | 2 Yes | 5 No |
What is s in c?
In a switch statement, what will happen if a break statement is omitted?
What is the purpose of the preprocessor directive error?
Write a program to reverse a linked list in c.
if a five digit number is input through the keyboard, write a program to calculate the sum of its digits. (hint:-use the modulus operator.'%')
What does == mean in texting?
Write a C program to remove the repeated characters in the entered expression or in entered characters(i.e) removing duplicates
Suppose I want to write a function that takes a generic pointer as an argument and I want to simulate passing it by reference. Can I give the formal parameter type void **, and do something like this? void f(void **); double *dp; f((void **)&dp);
What is the difference between typeof(foo) and myFoo.GetType()?
Write a program to remove the C comments(/* */) and C++ comments(//) from a file. The file should be declared in command line.
Write a c program to print the even numbers followed by odd numbers in an array without using additional array
What is the difference between CV and Resume ?