(1 mark) - (1 mark) Note that your code does not have to compile but you could implement it in Visual Studio to iron out problems. Please note that you need to explain each of your C# XML comments. Comments without a good explanation will result in loss of marks and may not be marked entirely. namespace Assign2 { // // This program is for CMP73010 Assignment 2 (2020) // // It calls some functions that need commenting // class Program { // // Mainline function // static void Main(string[] args) { int num1 = ReadNumber(); int num2 = ReadNumber(); FormatBinary(num1, "+", num2, Add(num1, num2)); Console.ReadLine(); } // // Read a single integer // public static int ReadNumber() { Console.Write("Number: "); try { return Convert.ToInt32(Console.ReadLine()); } catch (FormatException) { Console.WriteLine("illegal number format"); return 0; } } // // Formatted operation output // public static void FormatBinary(int n1, string op, int n2, int result) { 4 Console.WriteLine("{0} {1} {2} = {3}", n1, op, n2, result); } // // Add two integers // public static int Add(int n1, int n2) { return n1 + n2; } } } 5 Mark deductions (after): Demerit areas Marks Not using the report template (CMP73010_Assignment_2_Report_Template.docx) -3% Not writing Report Title, Student name, Student Number, etc. at the first page -1% Not writing the Executive Summary -1% Not writing the Introduction and Conclusion sections -1% Exceeding the maximum word-limit - 2% Late submission penalty 5% per day Notes: • Coversheet: Students must use the report coversheet, available at the Assessment page, to submit this assignment. Information regarding mark distribution, word-limit, etc. in the template file is for the whole assignment. • Word-limit: The maximum word-limit will be strictly applied. The marker can deduct marks for writing over this word-limit. So, make sure your report is completed within the given word-limit (1500 words). There is no maximum word-limit applicable for Title, Executive Summary and appendices. • Start early and submit on-time: Avoid any pitfalls that may arise due to late start. Thus, start your assignment as soon as possible to submit on-time. For late submissions, the standard assessment submission policy will be applied (see the unit profile). • Appendix: You may add appendices to document any additional material you wish to include such as tables, diagrams, figures, or other supplementary material. Appendices do not contribute to the word count of the document. • Reference: You should add a reference section and include any references, including publications (literature, books, etc.), which you want to refer to support your report. • Late Submission: This assignment will be due on Monday, 21st September, at 11:00 pm. A penalty of 5% of the available mark will be deducted from the actual mark for each day of late submission up to five days. • Consultation: You will have the opportunity to show your assignment draft to your tutors/lecturer/unit assessor for feedback. Several assignment consultation slots will be organised; follow the announcements from the unit assessor. • Contact: Please contact the tutor/lecturer/unit assessor if you have any issues or confusions.
Already registered? Login
Not Account? Sign up
Enter your email address to reset your password
Back to Login? Click here