math mode, also prints binary representation now
This commit is contained in:
parent
01802fe84e
commit
578594636a
1 changed files with 1 additions and 1 deletions
|
@ -232,7 +232,7 @@ fn calc(input: &str) -> String {
|
|||
};
|
||||
|
||||
match eval_expr(&mut tokens) {
|
||||
Ok(Value::Int(i)) => format!("{i} (0x{i:X})"),
|
||||
Ok(Value::Int(i)) => format!("{i} (0x{i:X}) (0b{i:b})"),
|
||||
Ok(Value::Float(f)) => format!("{f}"),
|
||||
Err(e) => e,
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue