edited by
638 views
0 0 votes

Find out the output of the given program?

include<stdio.h>
int main()
{
    char s[] = "Hello";
    char *ptr = s ;
    *ptr++; // please explain this line
     ptr++;
    printf("%s",ptr);
    return 0;
}

 

Please log in or register to answer this question.

Position:
Show:

Related questions

1 1 vote
2 2 answers
495
495 views
Vishnu__ asked Feb 4
495 views
#include <stdio.h>int mystery(int n) { if (n == 0) { return 0; } else if (n % 2 == 0) { return mystery(n / 2); } else { return 1 + mystery(n...
0 0 votes
1 1 answer
727
727 views
saket jaiswal asked Jan 22, 2025
727 views
code :1 #include <stdio.h int main() { char letters[] = {'A', 'B', 'C'}; for (int i = 0; i < 3; printf("%c", letters[i], i++)) { // Empty body } r...
3 3 votes
2 answers 2 answers
830
830 views
kirmada asked Jun 20, 2024
830 views
#include <stdio.h int main() { // Write C code here int i=10,*p, q, *r; p=&i; *p=15; q=&p; q=20; r=&q; *r=*p+1; printf("%d",i); return 0; }answer the output as integer ...
1 1 vote
0 0 answers
672
672 views
shivamSK asked Jun 19, 2024
672 views
#include <stdio.h void f(int (*x)(int)); int mysh(int); int (*sh)() = mysh; int main() { f(sh); sh++; for(int x=sh;x>=0;x ){ if(x){ printf("i am here"); }else{ printf("yo...