MCPcopy Create free account
hub / github.com/TheAlgorithms/Python / test_f1

Function test_f1

searches/hill_climbing.py:167–168  ·  view source on GitHub ↗
(x, y)

Source from the content-addressed store, hash-verified

165 doctest.testmod()
166
167 def test_f1(x, y):
168 return (x**2) + (y**2)
169
170 # starting the problem with initial coordinates (3, 4)
171 prob = SearchProblem(x=3, y=4, step_size=1, function_to_optimize=test_f1)

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected