Skip to content

lin-br/javando-do-lin

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 

Repository files navigation

About this project

I'm developing this project for both continuous learning and to improve my Java skills. It has codes, scripts, algorithms, challenges, exercises, annotations, comments, and more that I developed during this saga.

Challenges

[Kata] "Sort and Star" from CodeWars ✅

The description this challenge is: You will be given a vector of strings. You must sort it alphabetically (case-sensitive, and based on the ASCII values of the chars) and then return the first value. The returned value must be a string, and have "***" between each of its letters.

Examples:

  SortAndStar.do(new String[] {"bitcoin", "take", "over", "the", "world", "maybe", "who", "knows", "perhaps"}) // should return "b***i***t***c***o***i***n"
  SortAndStar.do(new String[] "turns", "out", "random", "test", "cases", "are", "easier", "than", "writing", "out", "basic", "ones"}) // should return "a***r***e"
  • Here you can see the result.
  • Here you can see the test results.

[Kata] "Split Strings" from CodeWars ✅

The description this challenge is: Complete the solution so that it splits the string into pairs of two characters. If the string contains an odd number of characters then it should replace the missing second character of the final pair with an underscore ('_').

Examples:

  StringSplit.solution("abc") // should return {"ab", "c_"}
  StringSplit.solution("abcdef") // should return {"ab", "cd", "ef"}
  • Here you can see the result.
  • Here you can see the test results.

[Kata] "Fake Binary" from CodeWars ✅

The description this challenge is: Given a string of digits, you should replace any digit below 5 with '0' and any digit 5 and above with '1'. Return the resulting string.

Examples:

  FakeBinary.fakeBin("45385593107843568") // should return "01011110001100111"
  FakeBinary.fakeBin("509321967506747") // should return "101000111101101"
  FakeBinary.fakeBin("366058562030849490134388085") // should return "011011110000101010000011011"
  • Here you can see the result.
  • Here you can see the test results.

[Kata] Convert string camel case to snake case ✅

Given a string in camel case, you should convert that to the string in snake case.

Examples:

  "toDo" // should return "to_do"
  "aBc" // should return "a_bc"
  "shouldReturnSnakeCase" // should return "should_return_snake_case"
  • Here you can see the result.
  • Here you can see the test results.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages