There is only ONE Rule to Win this competition: We will be Uploading logical question till December 31,2015. The one who solves maximum number of questions correctly will win the competition.
The Winner will be awarded with a PRIZE!!!!!
Very long answers are written in exam. Consider answers were written on console. Miss do not have time to read all answers. So she thinks of searching some key words in answer, which if all words are found than answer is correct. If atleast one word is matched, student gets answer half mark. Design a program which takes answer of student and key words to be searched in answer as inputs and if all found students gets "full marks".
Q
An already busy teacher is given a work to get students birthday and separate that dates whose year belongs to leap year. Format of date is specified by her superior is:"dd/mm/yyyy". Design a program to help her out taking input for number of students and their birth date one at a time.
Q
"What i feel?"
A number feels 'sad', 'happy' or 'ok'. Depending on, with how many number it can be formed(as a multiple), it feels. If less than 5 numbers, it would feel sad, more than 10 will make number happy else ok. Code to know what number feels.
Q
For a person a lucky number is the one which belongs to a series, (here series is mentioned from 7th position and only odd position numbers), which is:8,21,55,143...so on. At random he selects a number. Code to know whether number is lucky for him or not.
Q
You receive a credit C at a local store and would like to buy two items. You first walk through the store and create a list L of all available items. From this list you would like to buy two items that add up to the entire value of the credit. The solution you provide will consist of the two integers indicating the positions of the items in your list(smaller number first).
- One
line containing the value C, the amount of credit you have at
the store.
- One
line containing the value I, the number of items in the store.
- One
line containing a space separated list of I integers.
Each integer P indicates the price of an item in the
store.
- Each
test case will have exactly one solution.
Output
For each test case, output one line containing
"Case #x: " followed by the indices of the two items whose
price adds up to the store credit. The lower index should be output first.
Limits
5 ≤ C ≤ 1000
1 ≤ P ≤ 1000
Small dataset
N = 10
3 ≤ I ≤ 100
Large dataset
N = 50
3 ≤ I ≤ 2000