Explanation of the Solution | Classes and files

4. Katas

To see full version of Solution visit GitHub. See below↓

Solution:

  1. Create class.
  2. Create a constructor method in a class that takes one variable (a string). In the constructor itself, we define four variables (our string, a sheet of vowels and two files into which we will write our lines)
  3. Create a function to write a string to a file that takes a string and a file name.
  4. Create a function to convert a string to a string without vowels
  5. In the function:
    • Write a string to a new variable.
    • We run through the whole change and delete the vowels.
    • Write our string to a file.
    • Returning our string.
  6. Create a function for converting a string to a string without consonants, the same action algorithm as the previous function.
  7. We create a method for printing a class that will print a string that we need by convention.
  8. We call our classes with certain strings.
  9. Print classes.

That's all.

If you liked Katas, you can put star on this repositories, this will motivate me to write similar Katas for you.

Visit Github page: