May-30-2022, 04:09 AM
i get a line of data that may be indented much like Python code. i have bad code that tries things to see how much indentation there is. in C i could just step through the line and count the spaces until a non-space or the end of the line. i need to process tons of this kind of data over and over (a new format for genealogical data) so i've going through my code to speed things up. i'm looking at the indent counters and wondering if there is something better. sorry, no code samples of many bad ways. but the task is simple to describe: given a string (or bytes) how many spaces does it indent with. anything built-in that could speed this up?
Tradition is peer pressure from dead people
What do you call someone who speaks three languages? Trilingual. Two languages? Bilingual. One language? American.
What do you call someone who speaks three languages? Trilingual. Two languages? Bilingual. One language? American.