- Reverse a String 1
- Reverse Each Word
- Reverse a Sentence
- Palindrome
- Find Words
- CountIng Search
- Unique Characters
-
Java Sandwich - Anagrams 1
- Anagrams 2
- Counting Search 2
Java String Resources:
Java Sandwich
Premium Content - Free Preview
Time for some more challenging problems!
A "Java Sandwich" is a String that contains the word "Java" near the middle of it. "Near" means that the number of characters to the right and left differ by at most 2 characters.
End of Free Content Preview. Please Sign in or Sign up to buy premium content.
Comments
thales
Jul 23, 10:08 AMUhm a space is not a character right?
Learneroo
Jul 23, 10:15 AMIt shouldn't make a difference in this challenge, but a space is a character just like any other.
thales
Jul 23, 10:21 AMThx
it does matter since i have to count them in, right.
Learneroo
Jul 23, 10:44 AMYes that's correct, you need to count the spaces. (I thought there were the same number of spaces on each side, but I see that's not the case.)
thales
Jul 23, 11:26 AMI solved it, but i stil get wrong output one 1 item. The fault is not my code this thime! check it.
for 12Java12345 i get true and i thould be false. When i run it in eclips it gives false ( so its not my code).
what is going wrong?