Get startedGet started for free

Refining prompts for code changes

You are now reviewing the modifications that the AI model made in response to the prompt of the previous exercise:

“Improve readability and correctness of the calc_price() function. It's used to adjust prices dynamically in a motorbike rental site. Return your answer as Python code.”

What improvements could we make to this prompt to ensure the AI model modifies only what requested?

This exercise is part of the course

AI-Assisted Coding for Developers

View Course

Hands-on interactive exercise

Turn theory into action with one of our interactive exercises

Start Exercise