Spliting of a string

how to split a string on the basis of camel case

Let’s assume that the name of the string is str.
You have to do the following steps to split and print according to the camelCase :

  1. iterate the string
  2. keep printing str[i] and simultaneously keep checking the value of str[i+1]. If the value of str[i+1] falls inbetween β€˜A’ and β€˜Z’ then print endl.

Hope this helps.