Error
|
|
---|---|
@Ibrahim Nash | 5761 |
@blackshadows | 5701 |
@akhayrutdinov | 5111 |
@mb1973 | 4989 |
@Quandray | 4944 |
@saiujwal13083 | 4506 |
@sanjay05 | 3762 |
@marius_valentin_dragoi | 3516 |
@sushant_a | 3459 |
@verma_ji | 3341 |
@KshamaGupta | 3318 |
Complete Leaderboard | |
|
|
@aroranayan999 | 938 |
@bt8816103042 | 739 |
@SHOAIBVIJAPURE | 428 |
@codeantik | 412 |
@SherlockHolmes3 | 407 |
@neverevergiveup | 348 |
@mahlawatep | 347 |
@shalinibhataniya1097 | 343 |
@murarry3625 | 333 |
@saiujwal13083 | 326 |
@rohitanand | 314 |
Complete Leaderboard |
Given a number in decimal convert it to binary, a number in binary to decimal, decimal to hexadecimal and hexadecimal to decimal.
Input:
The first line of input takes the number of test cases, T . Then T test cases follow
Each test case contains 4 space separated integers, A in decimal, B binary,C decimal and D hexadecimal respectively.
Output:
Print 4 space separated integers representing the binary equivalent of A, decimal equivalent of B, hexadecimal equivalent of C and decimal equivalent of D respectively.
Constraints:
1<=T<=100
1<=A,C<=500
1<=B<=100000(base 2)
1<=D<=100000(base 16)
Example:
Input:
3
6 110 20 2A
10 111 25 FA
23 1011 22 FB4
Output:
110 6 14 42
1010 7 19 250
10111 11 16 4020
We strongly recommend solving this problem on your own before viewing its editorial. Do you still want to view the editorial?
Yes