diff options
author | San Jacobs | 2023-05-17 02:45:53 +0200 |
---|---|---|
committer | San Jacobs | 2023-05-17 02:45:53 +0200 |
commit | 38c882decf01a18a153ff590f166821dae69de31 (patch) | |
tree | f16e7579a6694e93938c490635ab1372c87e7809 /src/main.odin | |
parent | e12cbc76905216c33d280950f20283df1281b618 (diff) | |
download | satscalc-38c882decf01a18a153ff590f166821dae69de31.tar.gz satscalc-38c882decf01a18a153ff590f166821dae69de31.tar.bz2 satscalc-38c882decf01a18a153ff590f166821dae69de31.zip |
Still making epic strides
Diffstat (limited to 'src/main.odin')
-rw-r--r-- | src/main.odin | 17 |
1 files changed, 14 insertions, 3 deletions
diff --git a/src/main.odin b/src/main.odin index d4240ce..2030c2f 100644 --- a/src/main.odin +++ b/src/main.odin @@ -4,6 +4,10 @@ import "core:fmt" main :: proc() { test() + new_workday({0, 0, 1, 1, 1}, + {00, 08, 5, 5, 2023}, + {00, 23, 5, 5, 2023}, + {30, 21, 5, 5, 2023}) } test :: proc() { @@ -14,11 +18,11 @@ test :: proc() { fmt.println(toString(test_delta)) test_delta = {0, 0, 0} fmt.println(toString(test_delta)) - test_delta = {45, 12, 1} + test_delta = {0, 12, 2} fmt.printf("I've been waiting for %s! That's a long time!\n", toString(test_delta)) start: Moment = {45, 8, 20, 4, 2023} - end: Moment = {45, 8, 20, 4, 2023} + end: Moment = add(start, test_delta) block: Timeblock = {start, end, 0, ""} fmt.println(toString(block)) @@ -36,6 +40,7 @@ test :: proc() { fmt.println(toString(test_moment)) + fmt.println("\n--- TESTING OPERATIONS ---") fmt.printf("So far test_moment, holds: %s.\n", toString(test_moment)) @@ -46,13 +51,19 @@ test :: proc() { - fmt.println("\n--- TESTING DELTA ---") + fmt.println("\n--- TESTING DELTA & SORTABLE ---") + + fmt.printf("The sortable() version of %s is %i.\n", toString(test_moment), sortable(test_moment)) + fmt.printf("The sortable() version of %s is %i.\n", toString(test_delta), sortable(test_delta)) + fmt.printf("The diff() between %s and %s is %s.\n", toString(test_moment), toString(add(test_moment, test_delta)), toString(diff(test_moment, add(test_moment, test_delta)))) + //for i: int=1; i < 14; i += 1 { // fmt.println(days_in(i, 2023)) //} + fmt.println("") }
\ No newline at end of file |