diff options
author | Oskar <[email protected]> | 2024-08-29 16:24:16 +0200 |
---|---|---|
committer | Oskar <[email protected]> | 2024-08-29 16:24:16 +0200 |
commit | e039d589d29ab799c20fe845d5a005dc257f9a44 (patch) | |
tree | 6d89c035ee7c059813e0d34a8dc21f500ad27c1f /5p12.cpp | |
parent | 5cff617b2aa2148773256eed1a00607e0189529b (diff) |
more
Diffstat (limited to '5p12.cpp')
-rw-r--r-- | 5p12.cpp | 16 |
1 files changed, 16 insertions, 0 deletions
@@ -7,6 +7,22 @@ * */ +/* + The solution for this exercise is pretty ugly i will admit. + One other thing to note here is that the exercise can be + interpreted in various different ways. Should it count all + occurances of fl, ff, fi in one counter? Or should they all + have their own counters? I went with the first one but this + could just as well be the latter interpretation. I actually + thought this would be easy going in to it but i struggled + with bugs where i input strings like "fafafafa". Because it + would still count because whenever it encounters characters + that aren't f, i, l it does not reset the factive variable + so i added factive = false; to all the if statement blocks. + + Again, not pretty but it did the job. + */ + int main () { char Character = 0; |