From 897fe0c0d0e29875cfa32939237c9a6255c5d044 Mon Sep 17 00:00:00 2001 From: Damien George Date: Tue, 15 Apr 2014 22:03:55 +0100 Subject: py: Add builtin functions bin and oct, and some tests for them. --- tests/basics/builtin-hex.py | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 tests/basics/builtin-hex.py (limited to 'tests/basics/builtin-hex.py') diff --git a/tests/basics/builtin-hex.py b/tests/basics/builtin-hex.py new file mode 100644 index 0000000000..7d1c98a7a9 --- /dev/null +++ b/tests/basics/builtin-hex.py @@ -0,0 +1,12 @@ +# test builtin hex function + +print(hex(1)) +print(hex(-1)) +print(hex(15)) +print(hex(-15)) + +print(hex(12345)) +print(hex(0x12345)) + +print(hex(12345678901234567890)) +print(hex(0x12345678901234567890)) -- cgit v1.2.3