{"id":634,"date":"2023-03-02T16:08:05","date_gmt":"2023-03-02T16:08:05","guid":{"rendered":"https:\/\/blogs.glowscotland.org.uk\/es\/software\/?page_id=634"},"modified":"2023-03-02T16:10:16","modified_gmt":"2023-03-02T16:10:16","slug":"evaluation","status":"publish","type":"page","link":"https:\/\/blogs.glowscotland.org.uk\/es\/software\/software-design-and-development\/week-8\/evaluation\/","title":{"rendered":"Evaluation"},"content":{"rendered":"\n<p>The Evaluation phase is where the final product is compared to the requirements detailed in the analysis phase and if it can be declared as fit for purpose.<\/p>\n\n\n\n<p>It is important to consider the following when creating code:<\/p>\n\n\n\n<ul class=\"wp-block-list\"><li>Has the programmer used repetition (loops) where possible to reduce the amount of code?<\/li><li>Has the programmer used arrays (lists) where possible instead of declaring many individual variables?<\/li><li>Has the programmer used selection statements that will only make comparisons until a solution if reached?<\/li><li>Has the programmer used subprograms if the program needs to repeat a process at different points?<\/li><li>Has the programmer selected the correct data type for each variable?<\/li><\/ul>\n\n\n\n<p>If the answer to all of the above is yes, then the programmer has created software that makes efficient use of constructs.<\/p>\n\n\n\n<p>If the answer is no, then the programmer should be encouraged to go back to previous phases of development to make more efficient use of coding constructs.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Inefficient code:<\/h2>\n\n\n\n<pre class=\"wp-block-code\"><code>number1 = int(input(\"Please enter a number: \"))\nnumber2 = int(input(\"Please enter a number: \"))\nnumber3 = int(input(\"Please enter a number: \"))\nnumber4 = int(input(\"Please enter a number: \"))\n\nif number1 &gt; 20:\n    if number1 &lt; 40:\n        print(\"Number 1 is in the correct range\")\nif number2 &gt; 20:\n    if number2 &lt; 40:\n        print(\"Number 2 is in the correct range\")\nif number3 &gt; 20:\n    if number3 &lt; 40:\n        print(\"Number 2 is in the correct range\")\nif number4 &gt; 20:\n    if number4 &lt; 40:\n        print(\"Number 3 is in the correct range\")<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">Efficient code:<\/h2>\n\n\n\n<pre class=\"wp-block-code\"><code>numbers_array = &#091;]\nfor counter in range(4):\n    numbers_array.append(int(input(\"Please enter a number: \")))\n\n    if numbers_array&#091;counter] &gt; 20 and numbers_array&#091;counter] &lt; 40:\n       print(\"Number \" + str(counter + 1) + \" is in the correct range\")<\/code><\/pre>\n\n\n\n<p class=\"nextlink\"><a href=\"https:\/\/blogs.glowscotland.org.uk\/es\/software\/software-design-and-development\/week-8\/usability\/\" data-type=\"page\" data-id=\"639\">Next: Usability<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>The Evaluation phase is where the final product is compared to the requirements detailed in the analysis phase and if it can be declared as fit for purpose. It is important to consider the following when creating code: Has the programmer used repetition (loops) where possible to reduce the amount of code? Has the programmer&hellip; <a class=\"more-link\" href=\"https:\/\/blogs.glowscotland.org.uk\/es\/software\/software-design-and-development\/week-8\/evaluation\/\">Continue reading <span class=\"screen-reader-text\">Evaluation<\/span><\/a><\/p>\n","protected":false},"author":5710,"featured_media":0,"parent":28,"menu_order":4,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":""},"class_list":["post-634","page","type-page","status-publish","hentry","entry"],"_links":{"self":[{"href":"https:\/\/blogs.glowscotland.org.uk\/es\/software\/wp-json\/wp\/v2\/pages\/634","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blogs.glowscotland.org.uk\/es\/software\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/blogs.glowscotland.org.uk\/es\/software\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/blogs.glowscotland.org.uk\/es\/software\/wp-json\/wp\/v2\/users\/5710"}],"replies":[{"embeddable":true,"href":"https:\/\/blogs.glowscotland.org.uk\/es\/software\/wp-json\/wp\/v2\/comments?post=634"}],"version-history":[{"count":4,"href":"https:\/\/blogs.glowscotland.org.uk\/es\/software\/wp-json\/wp\/v2\/pages\/634\/revisions"}],"predecessor-version":[{"id":641,"href":"https:\/\/blogs.glowscotland.org.uk\/es\/software\/wp-json\/wp\/v2\/pages\/634\/revisions\/641"}],"up":[{"embeddable":true,"href":"https:\/\/blogs.glowscotland.org.uk\/es\/software\/wp-json\/wp\/v2\/pages\/28"}],"wp:attachment":[{"href":"https:\/\/blogs.glowscotland.org.uk\/es\/software\/wp-json\/wp\/v2\/media?parent=634"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}