# UVa 10473

Jump to navigation
Jump to search

## Contents

## 10473 - Simple Base Conversion[edit]

## Summary[edit]

Given a decimal of a hexadecimal number denoted by '0x' output hex for decimal number and decimal for hex number

## Explanation[edit]

- Read in the line as a string and parse it.

## Implementations[edit]

- Using atoi in the c library is a big plus.
- Code All the Problems

## Gotchas[edit]

ANY negative number ends input.

## Input[edit]

2147483647 4 7 44 0x80685 -1

## Output[edit]

0x7FFFFFFF 0x4 0x7 0x2C 525957