Python Script: Know your Hardware

Hello Friends,

Below is the script to know the information of your hardware. This scripts runs equally on windows and linux.*



import platform
import time

print(platform.system())    #the system/OS name

print(platform.release())    #the system’s release

print(platform.architecture())   #the system’s architecture

print(platform.processor())   # the (real) processor name

print(platform.machine())   #the machine type, e.g. 'i386'

print(platform.version())    #the system’s release version

from time import sleep      #this line stops the output on screen. No need of    
                                      #this if you are running through command line.
sleep(10)          





*all the script on this blog assumes that you are using python 3.0 or higher. 

Comments