Differences

This shows you the differences between two versions of the page.

Link to this comparison view

alf:teme:tema_en_1 [2021/03/06 20:50]
alexandru.radovici
alf:teme:tema_en_1 [2021/03/17 16:21] (current)
alexandru.radovici [Rules]
Line 7: Line 7:
 Deadline: **21st of March, 23:55**\\ Deadline: **21st of March, 23:55**\\
 Points: **1 point** out of the final grade\\ Points: **1 point** out of the final grade\\
-Link: \\+Link: [[https://​classroom.github.com/​a/​olSpOMPY|Homework 1]]\\
 Late upload: **1p / day** (maximum 2 days)\\ Late upload: **1p / day** (maximum 2 days)\\
 </​note>​ </​note>​
Line 199: Line 199:
 | 50% | stack and mathematical instructions | | 50% | stack and mathematical instructions |
 | 20% | jump instructions | | 20% | jump instructions |
-20% | labels |+10% | labels |
 | 10% | register instructions | | 10% | register instructions |
 | 10% | errors | | 10% | errors |
Line 208: Line 208:
 The homework has a lot of features that have to be implemented,​ we suggest you start like this: The homework has a lot of features that have to be implemented,​ we suggest you start like this:
   - Read the input file into s string and implement the ''​no file''​ error   - Read the input file into s string and implement the ''​no file''​ error
-  - Split the read input by ''​\n''​ (''​\n\r''​ if using windows, make sure top change it before you commit to git) string using the [[https://​developer.mozilla.org/​en-US/​docs/​Web/​JavaScript/​Reference/​Global_Objects/​String/​split|split]] function+  - Split the read input by ''​\n''​ (''​\r\n''​ if using windows, make sure top change it before you commit to git) string using the [[https://​developer.mozilla.org/​en-US/​docs/​Web/​JavaScript/​Reference/​Global_Objects/​String/​split|split]] function
   - Split each line by ' ' and extract the instruction and its parameters   - Split each line by ' ' and extract the instruction and its parameters
   - Implement the ''​unknown instruction''​ error   - Implement the ''​unknown instruction''​ error
Line 222: Line 222:
  
 ^ Instruction ^ Parameter ^ Details ^ ^ Instruction ^ Parameter ^ Details ^
-| write | number ​| Pops a number ​from the stack and writes ​it to the memory location defined by the parameter ​+| write | | Pops two numbers ​from the stack and writes ​the first one to the memory location defined by the second one 
-| read | number ​Reads a number from the memory location and pushes it to the stack |+| read | Pops a number from the stack and reads a number from the memory location ​defined bu the popped number ​and pushes it to the stack |
  
 <​note>​ <​note>​
Line 230: Line 230:
 ===== Rules ===== ===== Rules =====
  
-  - You may not use //RegEx// or any other library that would use regular expressions+  - You may not use //RegEx// or any other library that would use regular expressions ​(except \r?\n for splitting the input lines of the source)
   - Source code needs to be indented (-0.1p)   - Source code needs to be indented (-0.1p)
   - You need to explain in details in the Readme.md how you wrote the homework (-1p)   - You need to explain in details in the Readme.md how you wrote the homework (-1p)
alf/teme/tema_en_1.1615056627.txt.gz · Last modified: 2021/03/06 20:50 by alexandru.radovici
CC Attribution-Share Alike 3.0 Unported
www.chimeric.de Valid CSS Driven by DokuWiki do yourself a favour and use a real browser - get firefox!! Recent changes RSS feed Valid XHTML 1.0