#C++ - Nucleotide Count - What variable type am I supposed to return?

7 messages · Page 1 of 1 (latest)

tender wraith
#

Hi, I'm working on the C++ Nucleotide Count problem, and the text states


For example:

"GATTACA" -> 'A': 3, 'C': 1, 'G': 1, 'T': 2
"INVALID" -> error```

What I am confused by is the first example with "GATTACA". Am I returning a string from my nucleotide counting function? Am I returning an unordered map? And what function signature do I use so that the tests can call the right function? Here is the link for the whole page <https://exercism.org/tracks/cpp/exercises/nucleotide-count/edit>. If it helps, I am more familiar using Hackerrank type questions where the function signature is already defined and all I have to do is fill out the code within the function.
#

C++ - Nucleotide Count - What variable type am I supposed to return?

shy basin
#

If you look at the header file and/or tests, that should make it clear what is needed

#

The prose/text is generic and used for all tracks. The details are in the tests. Exercism takes a test-driven approach where details are usually discovered by running/reading tests

tender wraith
#

I see, thank you!

shy basin
#

You're welcome and good luck

#

If you can't figure it out, let us know!