Search
 
SCRIPT & CODE EXAMPLE
 

PYTHON

Python Program to Convert Decimal to Binary, Octal and Hexadecimal

# Python program to convert decimal into other number systems
dec = 344

print("The decimal value of", dec, "is:")
print(bin(dec), "in binary.")
print(oct(dec), "in octal.")
print(hex(dec), "in hexadecimal.")
Comment

PREVIOUS NEXT
Code Example
Python :: numpy matrix 
Python :: unix command in python script 
Python :: how to create a fixed size empty array in python 
Python :: changing axis labels matplotlib 
Python :: python yaml to dict 
Python :: joblib 
Python :: find columns with missing values pandas 
Python :: python rgb colors 
Python :: python find number of occurrences in list 
Python :: how to take input in 2d list in python 
Python :: spacy load en 
Python :: unable to get local issuer certificate python 
Python :: python set intersection 
Python :: how to change a header in pandas 
Python :: how do i print a list line by line in python 
Python :: python datetime format 
Python :: count lines in file python 
Python :: pandas dataframe delete column 
Python :: install virtual environment python mac 
Python :: python palindrome 
Python :: update set python 
Python :: api in python 
Python :: Python NumPy swapaxis Function Example 2 
Python :: Palindrome Check using for loop in python 
Python :: python pandas replace not working 
Python :: matplotlib logarithmic scale 
Python :: how to distribute a dataset in train and test using scikit 
Python :: pyspark groupby multiple columns 
Python :: how to read excel with multiple pages on pandas 
Python :: python print raw string 
ADD CONTENT
Topic
Content
Source link
Name
3+7 =