the assignment: "Write a program that stores all of the integers between 1000 and 9999 (inclusive) in an array. The program should display all of the 4-digit palindromes."
String has the method length(). I agree with Wietlol (yes, yes, I do): Get an IDE. It will tell you stuff that won't compile instantly without you having to compile it while offering fixes. Most of the stuff can be found by googling as well (ie how to I get the length of a String in Java)
@Wietlol So you cannot use a sneaky thing where you put the palindromes together.
i kind of need a multiplicative recursive method that outputs a tree based structure of nested rule matches that will then be flattened to a stream of lists of match trees
Test.java:16: error: cannot find symbol
for (int bar=eachInt.length;bar>0; bar--){
^
symbol: variable length
location: variable eachInt of type String
Test.java:20: error: cannot find symbol
if (eachInt.equals(reverse)) {
^
symbol: variable eachInt
location: class Test
2 errors
== English ==
=== Etymology ===
The oldest English-language use of the proverb has been found in Anne Isabella Thackeray Ritchie's (1837–1919) novel, Mrs. Dymond (1885), in a slightly different form:
" […] if you give a man a fish he is hungry again in an hour. If you teach him to catch a fish you do him a good turn.Possibly a translation of the ancient Chinese saying 授人以魚不如授人以漁/授人以鱼不如授人以渔 (shòu rén yǐ yú bùrú shòu rén yǐ yú). Other attributions have been suggested, but no solid evidence has been produced.
See the results of an exploration by Quote Investigator on https://quoteinvestiga...
Whatever ^^ I found that working the steps down why something doesn't work helps to understand underlying problem and helps at least me to remember and not do it again ^^
The President of the United States is the elected head of state and head of government of the United States. The president leads the executive branch of the federal government and is the commander-in-chief of the United States Armed Forces. The president is indirectly elected to a four-year term by the people through the Electoral College.
Since the office was established in 1789, 44 men have served as president. The first, George Washington, won a unanimous vote of the Electoral College. Grover Cleveland served two non-consecutive terms in office, and is counted as the nation's 22nd and 24...