diff options
| author | Sam Anthony <sam@samanthony.xyz> | 2023-07-29 11:19:55 -0230 |
|---|---|---|
| committer | Sam Anthony <sam@samanthony.xyz> | 2023-07-29 11:19:55 -0230 |
| commit | 008e4021375883610cf1b07e005a4176acadc0de (patch) | |
| tree | 3148bbf1945c8e0517810ea234e16c498f968eb4 /calc.go | |
| parent | c12813975d7529f864199b876bc3ee3b470c1c18 (diff) | |
| download | pfc-008e4021375883610cf1b07e005a4176acadc0de.zip | |
trig functions
Diffstat (limited to 'calc.go')
| -rw-r--r-- | calc.go | 12 |
1 files changed, 10 insertions, 2 deletions
@@ -5,9 +5,17 @@ import ( "strings" ) +type AngleMode int + +const ( + modeDeg = iota + modeRad +) + type Calculator struct { - stack Stack - buf string + stack Stack + buf string + anglem AngleMode } // swap swaps the values of the buffer and the bottom element of the stack. If |