epochs-demos commited on
Commit
82d9279
1 Parent(s): 98f0f0e

Upload app.py with huggingface_hub

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -70,7 +70,7 @@ def main():
70
 
71
  # Description of the challenge
72
  st.write("Create a function sum that meets the following criteria:")
73
- st.write('''sass''')
74
 
75
  func = 'sum'
76
  def execute_instructor_code(params):
@@ -86,7 +86,7 @@ def main():
86
  return instructor_function(*params)
87
 
88
  # Generate sample examples dynamically by executing the instructor's code
89
- test_cases = [(1, 2), (2, 3), (3, 4)]
90
  sample_examples = "\n".join([f"{func}({', '.join(map(str, params))}) -> {execute_instructor_code(params)}" for params in test_cases])
91
  st.code(sample_examples, language="python")
92
  show_solution_button = st.form_submit_button("Show Solution")
@@ -109,7 +109,7 @@ def main():
109
  return a+b''',
110
  code,
111
  'sum',
112
- [(1, 2), (2, 3), (3, 4)]
113
  )
114
  else:
115
  st.error("Please provide a solution.")
 
70
 
71
  # Description of the challenge
72
  st.write("Create a function sum that meets the following criteria:")
73
+ st.write('''Create a function that sums any two values''')
74
 
75
  func = 'sum'
76
  def execute_instructor_code(params):
 
86
  return instructor_function(*params)
87
 
88
  # Generate sample examples dynamically by executing the instructor's code
89
+ test_cases = [(1, 2), (100, 200), (0, 3)]
90
  sample_examples = "\n".join([f"{func}({', '.join(map(str, params))}) -> {execute_instructor_code(params)}" for params in test_cases])
91
  st.code(sample_examples, language="python")
92
  show_solution_button = st.form_submit_button("Show Solution")
 
109
  return a+b''',
110
  code,
111
  'sum',
112
+ [(1, 2), (100, 200), (0, 3)]
113
  )
114
  else:
115
  st.error("Please provide a solution.")