write a program in reverse the string without using
pointer,array,global variable declaration,lib fun only using
a function?
Answer Posted / sr amit tyagi
#include<stdio.h>
#include<conio.h>
void main()
{
FILE *f;
char c;
clrscr();
f=fopen("string","w");
while((c=getchar())!=EOF)
{
putc(c,f);
}
fclose(f);
f=fopen("string","r");
fseek(f,-1L,2);
do
{
putchar(getc(f));
}
while(!fseek(f,-2L,1));
fclose(f);
getch();
}
| Is This Answer Correct ? | 0 Yes | 7 No |
Post New Answer View All Answers
What does c mean in basketball?
Difference between strcpy() and memcpy() function?
What does %c mean in c?
What does calloc stand for?
When should you not use a type cast?
What is printf () in c?
write a program to find the given number is prime or not
What is a null pointer assignment error? What are bus errors, memory faults, and core dumps?
What are the back slash character constants or escape sequence charactersavailable in c?
Why is c called "mother" language?
What are actual arguments?
Is there sort function in c?
Write a program for Overriding.
Explain zero based addressing.
What is a stream?