Simple print two-level directory Python script

Source: Internet
Author: User
Tags python script
#!/bin/python
# coding:utf-8
s = "" "
* Host Information * * *
1 Basic information
2 CPU Information
3 Hard Drive information
4 Memory Information
5 Network card information

"""
While True:
I1 = input (s+ ' \ n Please enter the serial number: ')

if i1 == ‘1‘:    print(‘‘‘       1  主机名       2  当前登录用户数       3  操作系统       4  内核信息‘‘‘)elif i1 == ‘2‘:    print(‘‘‘       1  cpu 核心数       2  cpu 型号‘‘‘)elif i1 == ‘3‘:    print(‘硬盘信息‘)elif i1 == ‘4‘:    print(‘内存信息‘)elif i1 == ‘5‘:    print(‘‘‘       1  IP 地址信息       2  网卡流量信息‘‘‘)elif i1 == ‘d‘:    exit()else:    break

Simple print two-level directory Python script

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.