You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Reptile/单天航班信息查询.py

22 lines
635 B

# -*- coding: utf-8 -*-
"""
Created on Wed Nov 30 19:15:52 2022
@author: DELL
"""
import pandas as pd
df = pd.read_csv("contentt.csv", encoding=('gb2312'),names=["date","flightNum", "depTime", "arrTime", "price"])
df.head()
print(df)
while True:
print("***********************")
print('0...退出选择')
print('1...输入选择')
print("***********************")
menuId=eval(input("是否查询(输入数字):"))
if menuId==1:
riqi=input('请输入要查询的日期如2022-12-01')
df1=df[df.date==riqi]
print(df1)
elif menuId==0:
break