KIDZEE1G - Multiples

no tags 

Print all multiples of x between 1 to N.

1 থেকে N এর মধ্যে x এর সকল গুনিতক বের করতে হবে।

Input

First line specifies the test case number T (T ≤ 100). Then T test cases follow, each containing two integers, x and N, where 1 ≤ x ≤ N ≤ 1000000.

ইনপুট ফাইলের প্রথম লাইনে থাকবে টেস্ট কেসের সংখ্যা T (T≤100). এরপরে T সংখ্যক টেস্ট কেস থাকবে যার প্রতিটিতে দুটি করে পূর্ণ সংখ্যা x এবং N থাকবে যেখানে 1 ≤ x≤ N ≤ 1000000.

Output

For each line, print the case number and then list the multiples of x between 1 to N (inclusive) in ascending order. Separate two consecutive numbers by a single space character. Check sample input output for more details.

প্রতিটি লাইনে একটি করে কেস নম্বর প্রিন্ট করতে হবে এবং এরপরে 1 থেকে N এর মধ্যে x এর সকল গুনিতকগুলোকে ছোট থেকে বড় আকারে দেখাতে হবে। পাশাপাশি দু’টি সংখ্যাকে শুধুমাত্র একটি স্পেস দিয়ে আলাদা করতে হবে। নমুনা আউটপুটে আরো বিস্তারিত দেখতে পারো।

Example

Input:
3
4 11
13 50
2 10

Output:
Case 1: 4 8
Case 2: 13 26 39
Case 3: 2 4 6 8 10

hide comments
Samil Vargas: 2013-12-26 19:31:29

fuck you i dont know whats wrong give more testcases please :'(


Added by:Shafaet
Date:2013-01-09
Time limit:1s
Source limit:50000B
Memory limit:1536MB
Cluster: Cube (Intel G860)
Languages:All except: ASM64
Resource:Own problem - Used for Junior Training