← every case · 2000 · string forms
only the symbol that opened a string can close it, so the other kind inside is text. A counter that lets the other kind close it is left with a string open at the end of the line, so if its strings run across lines it counts the comment at the end as code
| 1 | codecodecodecodecodecodecode | a = "an apostrophe ' inside a double quoted string" |
| 2 | codecodecodecodecodecodecode | b = 'a quote " inside a single quoted string' |
| 3 | commentscommentscommentscommentscommentscommentscomments | # a real comment |
stringcommentthe tag around another language
cloc --json --config /tmp/linejudge-empty-file cases/2000-string_forms/2030-string_symbol_of_another_kind_inside/input.py
--strip-str-comments
cloc --json --config /tmp/linejudge-empty-file cases/2000-string_forms/2030-string_symbol_of_another_kind_inside/input.py --strip-str-comments
cloc --json --config /tmp/linejudge-empty-file cases/2000-string_forms/2030-string_symbol_of_another_kind_inside/input.py --docstring-as-code
codestats cases/2000-string_forms/2030-string_symbol_of_another_kind_inside/input.py --output json-compact --include-generated --no-gitignore --hidden --no-config
mezura cases/2000-string_forms/2030-string_symbol_of_another_kind_inside/input.py --output json --hide timing --no-default-config --no-local --counting content
mezura cases/2000-string_forms/2030-string_symbol_of_another_kind_inside/input.py --output json --hide timing --no-default-config --no-local --counting region
scc --format json --no-config cases/2000-string_forms/2030-string_symbol_of_another_kind_inside/input.py
tokei --output json cases/2000-string_forms/2030-string_symbol_of_another_kind_inside/input.py