4 ms·
f(x + dx) does look more conventional than (f (+ x dx)), but (/ numerator denominator) looks more like the conventional fraction syntax than putting a
by brlewis 10y ago
f(x + dx) does look more conventional than (f (+ x dx)), but
(/ numerator
denominator)
looks more like the conventional fraction syntax than putting a / somewhere in the middle of a line.
- Will_Parker 10y agoI'll give you that but also, ask 100 random people what "3/4" means and what "(/ 3 4)" means.
- klibertp 10y agoAre you sure random people are going to recognize "3/4" notation? It could be different for "3 ÷ 4", but I think "3/4" is not widely used outside of programming?
- archgoon 10y agoHave you ever looked at a cookbook? http://www.tasteofhome.com/recipes/how-to-cook/how-to-cut-down-recipes http://www.tasteofhome.com/recipes/how-to-cook/how-to-cut-do... Taken a drive? https://c1.staticflickr.com/5/4149/5174138836_6603010a7d_b.jpg https://c1.staticflickr.com/5/4149/5174138836_6603010a7d_b.j...
- omaranto 10y agoIt's used outside of programming in, say, mathematics. :)
- brlewis 10y agoYes, I'm sure hardly any would say "three fourths" for (/ 3 4) and a lot of them would for 3/4. (A lot of them might also say "three or four".) Incidentally Scheme syntax recognizes 3/4 as a rational number. It will do rational arithmetic without floating point problems.
- syncsynchalt 10y agoRacket (and others?) gives you a sugar of (n . / . d) to infix any two-arg function if that's a stumbling block.
- deleted 10y ago[deleted]
- int_19h 10y agoI don't know, things like 1/2 are pretty conventional fraction syntax. But if you really wanted to, you could always do the same thing in Python, since newlines are basically just ignored inside parentheses: (numerator / denominator) Or even place / on its own line if so desired.