Ranter
Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
Comments
-
main = replicateM_ 2 . flip mapM_ weights $ \s -> print s >> putStrLn "Rest"
Or, avoiding lambda:
main = replicateM_ 2 . flip mapM_ weights $ (>> putStrLn "Rest") . print -
@highlight
#include <stdio.h>
int main() {
int weights[] = {12|0x80, 15, 17|0x80, 22|0x80, 0};
for (int _sets = 0; _sets < 2; ++_sets)
{
for (int *w = weights; *w != 0; ++w)
{
char *half = *w & 0x80 ? ".5" : "";
printf("%d%s\nRest\n", *w & ~0x80, half);
}
}
} -
@bkwilliams jesus thank you; if you're doing ascension/descension sets, put your weights back between sets.
Me in the Gym πππ
weights = [12.5, 15, 17.5, 22.5]
sets = 0
while (sets <2):
for i in weights:
print(i)
print("Rest")
sets = sets + 1
And people say keep your work at office.
random