write a fuction for accepting and replacing lowercase
letter to'Z' with out using inline function.
Answers were Sorted based on User's Feedback
Answer / sandhya.kakani
#include<stdio.h>
#include<string.h>
main()
{
char ch;
clrscr();
printf("enter any character");
scanf("%c",&ch);
if(ch>=97&&ch<=122)
{
printf("u enterd small letter \n");
function(ch);
}
}
function(char c)
{
char c='z';
printf("replaced lower case letter into uppercase %c",c);
}
Is This Answer Correct ? | 19 Yes | 8 No |
Answer / bavi
#include<stdio.h>
main()
{
char ch;
void replet(char);
prinf("Enter the character:");
scanf("%c",&ch);
if(ch>=65&&ch<==90)
{
printf("The character %c entered is UPPERCASE",ch);
replet(ch);
}
else
printf("The given character %c is lowercase",ch);
}
void replet(char ch)
{
ch='Z';
printf("The replaced character is %c",ch);
}
Is This Answer Correct ? | 10 Yes | 1 No |
Answer / clement
#include<stdio.h>
#include<string.h>
main()
{
char ch;
clrscr();
printf("enter any character");
scanf("%c",&ch);
if(ch>=97&&ch<=122)
{
printf("u enterd small letter \n");
function(ch);
}
}
function(char c)
{
c='Z';
printf("replaced lower case letter into uppercase %c",c);
}
Is This Answer Correct ? | 12 Yes | 6 No |
Answer / balu
#include<stdio.h>
#include<string.h>
main()
{
char ch;
printf("enter any character:\t");
scanf("%c",&ch);
if(ch>=97&&ch<=122)
{
printf("u enterd small letter \n");
function(ch);
getch();
}
else
printf("you entered the capital letter");
getch();
}
function(ch)
{
char c='z';
printf("replaced lower case letter into uppercase %c",c);
}
Is This Answer Correct ? | 3 Yes | 3 No |
Answer / dhakchina moorthy.p
#include<stdio.h>
main()
{
char ch;
void replet(char);
prinf("Enter the character:");
scanf("%c",&ch);
if(ch>=65&&ch<==90)
{
printf("The character %c entered is lowercase",ch);
replet(ch);
}
else
printf("The given character %c is uppercase",ch);
}
void replet(char ch)
{
ch='Z';
printf("The replaced character is %c",ch);
}
Is This Answer Correct ? | 4 Yes | 7 No |
struct screen_pos{ int row, col } ;move_right(cursor)struct screen_pos *cursor;{ cursor.col++; } /* This statementhas a syntax error */What is the correct statement a) cursor.col = cursor.col + 1; b) col.cursor++; c) *cursor.col++; d) pointer
Create a simple code fragment that will swap the values of two variables num1 and num2.
What are the 5 organizational structures?
What is c system32 taskhostw exe?
Find string palindrome 10marks
5 Answers Honeywell, Infosys, Riktam, Roland,
How can I recover the file name given an open stream or file descriptor?
What is break statement?
How to print India by nested loop? I IN IND INDI INDIA
can we store values and addresses in the same array? explain
Why does the call char scanf work?
What is the purpose of macro in C language?
List the difference between a While & Do While loops?