TaliaKorobkin commited on
Commit
0cbdef8
1 Parent(s): 3bd8c5b

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +20 -1
app.py CHANGED
@@ -1,2 +1,21 @@
1
  import streamlit as st
2
- st.markdown('Hello World')
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  import streamlit as st
2
+ import time def main():
3
+ st.title("File Upload and Display")
4
+
5
+ # File upload
6
+ uploaded_file = st.file_uploader("Upload a file")
7
+
8
+ if uploaded_file is not None:
9
+
10
+ # Display file contents using st.markdown()
11
+ file_contents = uploaded_file.read().decode("utf-8")
12
+ st.markdown("### File Contents:") st.markdown(f"```{file_contents}```")
13
+
14
+ # Wait for 5 seconds
15
+ time.sleep(5)
16
+
17
+ # Show completed message
18
+ st.success("File processing completed!")
19
+
20
+ if __name__ == "__main__":
21
+ main()