Challenging problems

Mario like music in C program
C Programming
Challenging problems

Mario like music in C program

#include <windows.h> #include<stdlib.h> #include<stdio.h> int ma in() { int a=1; mariomusic(); return 0; } int mariomusic() { Beep (330,100);Sleep(100); Beep (330,100);Sleep(300); Beep (330,100);Sleep(300); Beep (262,100);Sleep(100); Beep (330,100);Sleep(300); Beep (392,100);Sleep(700); Beep (196,100);Sleep(700); Beep (262,300);Sleep(300); Beep (196,300);Sleep(300); Beep (164,300);Sleep(300); Beep (220,300);Sleep(100); Beep (246,100);Sleep(300); Beep (233,200); Beep (220,100);Sleep(300); Beep (196,100);Sleep(150); Beep (330,100);Sleep(150); Beep (392,100);Sleep(150); Beep (440,100);Sleep(300); Beep (349,100);Sleep(100); […]

Read More
Indian Railway – Seating arrangement for Sleeper Class
C Programming
Challenging problems

Indian Railway – Seating arrangement for Sleeper Class

Write a program to determine the type of berth when the seat/berth number in the train is given. Input Format: Input consists of a single integer. Assume that the range of input is between 1 and 72. Output Format: Output consists of a single string. [Upper or Middle or Lower or Side Lower or Side Upper] Sample Input 2: […]

Read More
C Programming
Challenging problems

Zero Duplicates

Write a program that will read in a list of numbers and will then print out the same list except numbers that have already been printed will be printed as a zero instead. Sample Input : 4 3 2 1 4 Sample Output: 3 2 1 0 code: #include<stdio.h> int main() { int n,i,j; int […]

Read More
C Programming
Challenging problems

Panagram in c

#include<stdio.h> #include<conio.h> #include<string.h> int main() { int x[26]={0},i,n; char c[100]; clrscr(); gets(c); n=strlen(c); for(i=0;i<n;i++) { if(c[i]>=65&&c[i]<=90) x[c[i]-26]++; else if(c[i]>=97&&c[i]<=122) x[c[i]-97]++; } for(i=0;i<26;i++) { if(x[i]==0) { break; } } if(i==26) { printf(“panagram”); } else { printf(“not panagram”); } return 0; }

Read More
C Programming
Challenging problems

C Program to find two given strings are anagram or not

Write a program to find whether the 2 given strings are anagrams or not. Anagrams are words or phrases made by mixing up the letters of other words or phrases,  Input and Output Format: Input consists of 2 string. Assume that all characters in the string are lowercase letters or spaces and the maximum length of […]

Read More
C Programming
Challenging problems

SMS Language In C

In this tutorial, we will learn how to convert plain English text message into SMS Language In C Programming language. What is SMS Language? SMS Language is also known as slang used in mobile phones that are trendy these days. SMS Language(Abbreviation) English word s yes u you 2day today y why The above table showcases some of […]

Read More
C Programming
Challenging problems

ENCODING program In C Programming Language

In this C Programming tutorial, We will learn how to Encoding in C Programming Language. We are going to implement a C program based on an interesting table with some rules. I  will advise you to first try to solve it with yourself and if you need any help then check out the code mention […]

Read More
C Programming
Challenging problems

Cipher-decipher Program in C

In the language of cryptography, ciphertext refers to a message encoded with a particular key. Plaintext refers to the original, unencoded text. In this problem, both the ciphertext and the key are simply strings of upper-case characters. The ciphertext is generated from the plaintext by “adding” corresponding characters of the plaintext and the key together. […]

Read More