Refactoring Java Code: How to refactor code to write cleaner and more maintainable code.

Publicado el: 17 junio 2020
en el canal de: Pragmatic Ways
12,471
173

[UPDATED CODE to this assignment can be found online at https://www.pragmaticways.com/refacto...]

In this video we go through some more refactoring techniques to write cleaner code with this homework submissions.

(If you want to submit some code to get refactored through a video, then join the Software Engineering Mastermind Group on facebook!   / softwareengineeringmastermindgroup  )

--------
Here are the instructions for this assignment:
You are driving a little too fast, and a police officer stops you.
Write a method to compute the result:
0 = no ticket
1 = small ticket
2 = big ticket

If speed is 60 or less, the result is 0.
If speed is between 61 and 80 inclusive, the result is 1.
If speed is 81 or more, the result is 2.

Unless it is your birthday, on that day, your speed can be 5 higher in all cases.

caughtSpeeding(60, false) → 0
caughtSpeeding(65, false) → 1
caughtSpeeding(65, true) → 0
-------

You can find examples to all the code (the old code and the new refactored code) on the website at https://www.pragmaticways.com/refacto...


En esta página del sitio puede ver el video en línea Refactoring Java Code: How to refactor code to write cleaner and more maintainable code. de Duración hora minuto segunda en buena calidad , que subió el usuario Pragmatic Ways 17 junio 2020, comparta el enlace con amigos y conocidos, en youtube este video ya ha sido visto 12,471 veces y le gustó 173 a los espectadores. Disfruta viendo!