import streamlit as st # Title of the app st.title("Hello App") # Text input from user name = st.text_input("Enter your name") # Button to submit the input if st.button("Submit"): if name: st.success(f"Hello, {name}!") else: st.warning("Please enter your name.") # Clear button if st.button("Clear"): st.rerun() # Updated from st.experimental_rerun() to st.rerun()