write a programe returns the number of times the character
appears in the string
Answers were Sorted based on User's Feedback
Answer / vignesh1988i
#include<stdio.h>
#include<conio.h>
void main()
{
char a[50],q;
int count =0;
printf("enter the sring :");
gets(a);
printf("enter the char. to be searched :");
scanf("%c",&q);
for(int i=0;a[i]!='\0';i++)
{
if(a[i]==f)
count++;
}
printf("the occurance is :%d",count);
getch();
}
| Is This Answer Correct ? | 3 Yes | 4 No |
write a program that will accept two integers and will implement division without using the division operator if the second value is an odd number and will implement multiplication without using multiplication operator if the second value is an even number.
what is constant pointer?
Is c high or low level?
enum { SUNDAY, MONDAY, TUESDAY, }day; main() { day =20; printf("%d",); getch(); } what will be the output of the above program
What is an example of enumeration?
convert 12345 to 54321 withoutusing strig
What is sizeof return in c?
Write the program for displaying the ten most frequent words in a file such that your program should be efficient in all complexity measures.
Why is c so important?
The program will first compute the tax you owe based on your income. User is prompted to enter income. Program will compute the total amount of tax owed based on the following: Income Tax 0 - $45,000 = 0.15 x income $45,001 - $90,000 = 6750 + 0.20 x (income – 45000) $90,001 - $140,000 = 15750 + 0.26 x (income – 90000) $140,001 - $200,000 = 28750 + 0.29 x (income – 140000) Greater than $200,000 = 46150 + 0.33 x (income – 200000) Dollar amounts should be in dollars and cents (float point numbers with two decimals shown). Tax is displayed on the screen.
Do you know what are the properties of union in c?
Do you know what is a programing language ?