diff --git a/.obsidian/workspace.json b/.obsidian/workspace.json index b4c4aa9..c359e63 100644 --- a/.obsidian/workspace.json +++ b/.obsidian/workspace.json @@ -13,7 +13,7 @@ "state": { "type": "markdown", "state": { - "file": "UNB/Year 5/Semester 1/HIST1001/In class notes.md", + "file": "UNB/Year 5/Semester 1/CS3113/In class notes.md", "mode": "source", "source": false } @@ -85,7 +85,7 @@ "state": { "type": "backlink", "state": { - "file": "UNB/Year 5/Semester 1/HIST1001/In class notes.md", + "file": "UNB/Year 5/Semester 1/CS3113/In class notes.md", "collapseAll": false, "extraContext": false, "sortOrder": "alphabetical", @@ -102,7 +102,7 @@ "state": { "type": "outgoing-link", "state": { - "file": "UNB/Year 5/Semester 1/HIST1001/In class notes.md", + "file": "UNB/Year 5/Semester 1/CS3113/In class notes.md", "linksCollapsed": false, "unlinkedCollapsed": true } @@ -125,7 +125,7 @@ "state": { "type": "outline", "state": { - "file": "UNB/Year 5/Semester 1/HIST1001/In class notes.md" + "file": "UNB/Year 5/Semester 1/CS3113/In class notes.md" } } } @@ -149,8 +149,10 @@ }, "active": "a06cabd352081cbd", "lastOpenFiles": [ - "UNB/Year 5/Semester 1/HIST1451/In class notes.md", "UNB/Year 5/Semester 1/HIST1001/In class notes.md", + "UNB/Year 5/Semester 1/CS3113/In class notes.md", + "UNB/Year 5/Semester 1/CS3113", + "UNB/Year 5/Semester 1/HIST1451/In class notes.md", "UNB/Year 5/Semester 1/HIST1001", "UNB/Year 5/Semester 1/HIST1451", "UNB/Year 5/Semester 1", diff --git a/UNB/Year 5/Semester 1/CS3113/In class notes.md b/UNB/Year 5/Semester 1/CS3113/In class notes.md new file mode 100644 index 0000000..dce1417 --- /dev/null +++ b/UNB/Year 5/Semester 1/CS3113/In class notes.md @@ -0,0 +1,24 @@ +## Convert numbers to binary +Number in decimal: 53.7 +### Decimal conversion + +| Calculation | Remainder/Binary | +| ----------- | ---------------- | +| 53 / 2 = 26 | 1 | +| 26 / 2 = 13 | 0 | +| 13 / 2 = 6 | 1 | +| 6 / 2 = 3 | 0 | +| 3 / 2 = 1 | 1 | +| 1 / 2 = 0 | 1 | +So in binary 110101, as the order is in reverse of the decimals +### Fraction Conversion + +| Calculation | Non Decimal Portion/Binary | +| ------------- | -------------------------- | +| 0.7 x 2 = 1.4 | 1 | +| 0.4 x 2 = 0.8 | 0 | +| 0.8 x 2 = 1.6 | 1 | +| 0.6 x 2 = 1.2 | 1 | +| 0.2 x 2 = 0.4 | 0 | +And so on.. so the fraction would be .10110, with 0110 repeating infinitely +So the final number would be 110101.10110... \ No newline at end of file