~torresjrjr/dc

1454fba354853153985a55e39d75493c4649f170 — Byron Torres a month ago 9af0cd2
add v sqrt cmd
1 files changed, 7 insertions(+), 0 deletions(-)

M dc.ha
M dc.ha => dc.ha +7 -0
@@ 179,6 179,13 @@ fn dc(in: io::handle) void = {
			const b = pop();
			const a = pop();
			push(math::powf64(a, b));
		case 'v' =>
			if (len(S) < 1) {
				fmt::errorln("dc: stack has too few elements")?;
				continue;
			};
			const a = pop();
			push(math::sqrtf64(a));
		case =>
			fmt::errorfln("dc: unimplemented '{}'", r)?;
		};