Quote:
How to find all substrings of a given string
With a sheet of paper and a pencil, you get something like:
- imput string= "abcdef"
- substrings: "a" "ab" "abc" "abcd" "abcde" "abcdef" "b" "bc" "bcd" "bcde" "bcdef" "c" "cd" "cde" "cdef" "d" "de" "def" "e" "ef" "f"
- find which operations give the substrings in order and what are the changes between 2 of them.
- deduce the algorithm and write code.
We do not do your HomeWork.
HomeWork is not set to test your skills at begging other people to do your work, it is set to make you think and to help your teacher to check your understanding of the courses you have taken and also the problems you have at applying them.
Any failure of you will help your teacher spot your weaknesses and set remedial actions.