import streamlit as st name = st.text_input("请输入你的名字:") if st.button("打招呼"): st.write(f"你好,{name}!")