{"trustable":false,"sections":[{"title":"","value":{"format":"HTML","content":"\u003cp\u003e \u0026nbsp;\u003c/p\u003e \n\u003ctable\u003e \n \u003ctbody\u003e \n \u003ctr\u003e \n \u003ctd\u003e \u003ch1\u003e \u003cb\u003e\u0026nbsp;\u003ca\u003e Simple Base Conversion\u003c/a\u003e\u0026nbsp;\u003c/b\u003e\u003c/h1\u003e \u003c/td\u003e \n \u003c/tr\u003e \n \u003c/tbody\u003e \n\u003c/table\u003e \n\u003cp\u003e In this problem you are asked to write a simple base conversion program. You will be given a hexadecimal or decimal integer number as input. You will have to output the corresponding decimal or hexadecimal number. Hexadecimal numbers always starts with a `0x\u0027 and all other numbers are to be considered as decimal numbers. There will be no invalid numbers in the input.\u003c/p\u003e \n\u003cp\u003e \u0026nbsp;\u003c/p\u003e \n\u003cdiv\u003e \n \u003cimg align\u003d\"BOTTOM\" alt\u003d\"\\epsfbox{p10473.eps}\" height\u003d\"263\" src\u003d\"http://uva.onlinejudge.org/external/104/p10473.gif\" width\u003d\"469\" /\u003e\n\u003c/div\u003e \n\u003cp\u003e \u0026nbsp;\u003c/p\u003e \n\u003ch2\u003e \u003ca\u003e Input\u003c/a\u003e\u003c/h2\u003e \n\u003cp\u003e The input file contains several lines of input. Each line contains a single non-negative number, which may be a decimal or hexadecimal number as explained in the problem statement. The decimal value of this number will be less than 2\u003csup\u003e31\u003c/sup\u003e. A line containing a negative decimal number terminates input. This number should not be processed. Input numbers will contain no space within them.\u003c/p\u003e \n\u003cp\u003e \u0026nbsp;\u003c/p\u003e \n\u003ch2\u003e \u003ca\u003e Output\u003c/a\u003e\u003c/h2\u003e \n\u003cp\u003e For each line of input (Except the last one) produce one line of output. This line should contain the decimal or hexadecimal representation of the corresponding hexadecimal or decimal number. Like the input, the hexadecimal numbers in the output should be preceded by a `0x\u0027.\u003c/p\u003e \n\u003cp\u003e \u0026nbsp;\u003c/p\u003e \n\u003ch2\u003e \u003ca\u003e Sample Input\u003c/a\u003e\u003c/h2\u003e \n\u003cpre\u003e\r\n4\r\n7\r\n44\r\n0x80685\r\n-1\r\n\u003c/pre\u003e \n\u003cp\u003e \u0026nbsp;\u003c/p\u003e \n\u003ch2\u003e \u003ca\u003e Sample Output\u003c/a\u003e\u003c/h2\u003e \n\u003cpre\u003e\r\n0x4\r\n0x7\r\n0x2C\r\n525957\r\n\u003c/pre\u003e \n\u003cp\u003e \u0026nbsp;\u003c/p\u003e \n\u003cp\u003e \u0026nbsp;\u003c/p\u003e \n\u003cp\u003e Problem-setter: Shahriar Manzoor, ACM Valladolid Online Judge\u003c/p\u003e"}}]}