I wish every language, whether functional or imperative, had expression-based loops similar to for/list
and for/fold
, which make equally as much sense functional as imperative.
I wish every language was Racket.
Not to spill the kool-aid, but sometimes I wish Racket was a bit more CL-y. For example, I can’t stand that functions like take
and drop
raise exceptions when attempting to take/drop too many items instead of just gracefully working with what’s there.
I especially don’t like the answers that try to say “Loops don’t make sense in a pure functional program.” Loops do make sense in a pure-functional program, as long as they’re expression-based and not statement-based / effect-based. List comprehensions, for/list
, for/fold
, named-let, etc. are all loops that make perfect sense functionally
Absolutely. I do very much like my named let loops though. So flexible.
(like cross-recursion)
(or passing the continuation to another function)
I am working on the typography (css) on my math project. Any advice?
I am absolutely not an expert, but I’d be interested in comparing this to a version that uses a sans-serif face for both of the heading levels.
Sans serif for the “1. Geometri” ? Let’s try that.
This is sans serif for everything:
Except the math where I don’t have a choice (MathJax 3 only has one font).
I was thinking that the body text would stay serif. But, again, I have no idea what I’m talking about.
Looks nice. Obviously a personal preference for serif vs. sans tho
@jaz It was by accident the body went sans serif :slightly_smiling_face: I’ll try to make a “sans serif headers” with “serif body” version.
Not sure what you want thoughts on (just CSS, math, anything)? But some random thoughts…
• More spacing between headings and body text might be helpful • Adding “fig 1, 2, …” to the images and then referencing them in the text may be useful if the same figures are used multiple times. For example, T = 1/2 * h^2 * a
references ‘a’, but the figure immediately next to it has “A” at a vertex and not a side/length. It’s obviously referencing another figure on the page, but it’s not [immediately] clear which one? • Maybe a personal preference, but it’s easier to read a/2
instead of 1/2 * a
. You also won’t need parens as often (e.g. a+b+c / 2
). • Is it possible to add extra padding/whitespace between =
in the equations? Especially with the 1/2
’s in there, the lines bleed a bit for those with less-than-awesome eyesight. :slightly_smiling_face:
But seriously, it looks nice. The background color is perfect and contrasts quite well. The figures to the side is wonderful. Good spacing between text and equations and figures.
Thanks for the feedback. It’s just the thing I need.
One last thought, given that you have the T = ... = ... = ...
in there, which shows equality. If you also have places showing simplification, be sure to do those on new lines. For example: T = ...
= ... simplified
= ... even more simplified
= ... answer!
I’ll experiment with more spacing.
The “Is it possible to add extra padding/whitespace between =
in the equations?” - is this due to the png? (I need to click twice on the image in Slack to get a 100% image)
But do you mean space on each side of = or a different = with more vertical space between the lines in = ?
Oh. At 100% it’s definitely more legible. I meant more horizontal padding. e.g. from A=B
to A = B
.
But I don’t know how much control you have over the math rendering.
That’s certainly doable. I am using racket-cas to convert math as s-expression into TeX, so that’s an easy change.
I think I prefer your original version :)
I agree with the a/2 and do that as default. Here it just happen to be the area of a triangle, which verbally (at least in Danish) is “half height times base” so I want the formula to read the same.
That’s a result too :-)
+1. Also, cool to learn that was Danish. I had no idea (was guessing Finnish). :slightly_smiling_face:
Different language lineage :slightly_smiling_face:
I know English and Russian. After that, I’m guessing. :smile:
I’ll definitely give that watch. Thanks! I love learning the etymology of words, slang, and phrases in different languages. If that gets into it, I’ll binge it as well, I think.
I also love how language is influenced by culture.
For fun I have attempted to learn some French. I then noticed that quite a few words in english have two versions: one “french” and one “normal”.
Were the “serif” body better than the “sans serif” body?
I personally prefer sans serif only because it’s less noise on the page. But that’s always going to be a personal preference, I think.
Originally I chose “serif” to make it look “book like” and also to get the body font and math font to match - but looking at again - I am not so sure.
Maybe you could make it a user preference? “Hey, don’t like how it looks? Suit yourself! Here are some parameters.”
I think I heard long ago that the sans serif was better on the web, or maybe on mobile devices.
Maybe we you hover over “fig 1” you get a little preview of the figure. Then if you hold down the shift key you see the whole figure, if you release the shift key it goes back to the preview so you can see the text that mentioned fig 1.
I learned that too back in the day. Reading up on it - it seems the reasoning was that serifs were terrible on screens with low resolution. Now most screens have high resolution (maybe mobiles are the exception?), so serifs aren’t in bad standing anymore.
I still use sans serif for Keynote/PowerPoints for the same reason.
Just found this page. The font used in the body might be a good compromise.
http://chalkdustmagazine.com/blog/is-there-a-perfect-maths-font/