import streamlit as st | |
def translate(text): | |
return "Hello " + text | |
if __name__ == "__main__": | |
st.title("Text Translator") | |
input_text = st.text_input("Enter text:") | |
if st.button("Translate"): | |
output_text = translate(input_text) | |
st.write("Translated text:", output_text) | |