Joined Jan 29, Messages 1, I thought to make a FAQ so that new people to the boards will get their questions answered. In the top, second row, there is a small yellow box with a picture of mountains with a sun. You will be asked to put in the URL of the image, do so and press enter.
Spoiler 10chars. Spoiler Lucario. Spoiler But, when Ness was added, people used the phase to annoy those who thought he was gone. Spoiler Toon Zelda Zelda alternate cosume? Mario, Dixie Kong Diddy Kong alternate costume? Joined Sep 23, Messages Location confirmed. Sending supplies. You for got 10Charmanders. You also left out 10crocodiles.
Kazuma Smash Cadet. Joined Jan 3, Messages NDUDE said:. DeuceBlade Smash Champion. Joined Oct 10, Messages Location Delaware. Collective of Bears King of Hug Style. Ouendanation Smash Ace. This thread is really unneccessary You also forgot 10landmasters. Antinegative Smash Apprentice.
I'm ashamed to admit this but I thought it was some deluded ranking system; people really enjoy a post so they give it ten out of ten charizards. L-ectrico Smash Apprentice. I'm not going to post every 10 insert word here thing, so get over that. Joined Feb 11, Messages Location California. I like Spoiler 10charizards.
Downfall Smash Apprentice. Spoiler 10colonoscopies. Ok, enough 10chunkychinesenoodlesonasticks, I actually needs on topic thread ideas. Xarias Smash Journeyman. I can't believe noobs are so nooby, they can't put two and two together to figure out what 10char means. But then again, they ARE noobs Joined Feb 8, Messages Darkslash Smash Master.
Smash Lord. Joined Feb 21, Messages 1, Location Toronto. What does ITT mean? Xarias said:. And no, I figured out what 10char meant very easily. I used my brain, see. I did this thing called reading comprehension, mixed with context clues, as well as noticing the obvious.
Maybe I should try to make a very short post and see what happens? Well, I guess its 10 of 'char'. But what is char? Characters, as in letters and numbers! You need 10 characters to post! There are several ways to finding out stuff, asking, experimenting, experience, drawing conclusions, I need more noob questions.
You didn't mention that meteor smashes can be meteor cancelled; spikes cannot. Heres a n00b question. What does FTW mean? Game and Pichu Smash Journeyman. ITT means in this topic. Game and Pichu said:. Viewed k times. What's your aversion to checking length or catching an exception? OUt of curiosity, why do you want to avoid the size check. This is not C. Add a comment. Active Oldest Votes. Stephen C Stephen C k 90 90 gold badges silver badges bronze badges.
I disagree with what you are saying. If this is wrapped in a function, it doesn't matter what is inside the function , and any "neatness" is definitely out-weighed by lack of clarity. The point of this solution is that it is "neat" for the case where you don't want to create a wrapper function. It would be neater to use StringUtils. I'm not convinced that preventing NPEs is a good thing.
An NPE means you should have a null in s. It is a sign of a bug, not something that should be hidden. Dealing with a null is not part of the OP's stated requirements. Don't reinvent the wheel Dave Jarvis Nickkk Nickkk 1, 1 1 gold badge 7 7 silver badges 2 2 bronze badges.
It doesn't answer the question, but regardless it still provides the solution. If the OP is able to understand, I think this is a better solution. It might also be useful to point out that StringUtils. The former is from StringUtils , while the latter is using String. The last Parameter of StringUtils. Skuli Skuli 1, 2 2 gold badges 19 19 silver badges 28 28 bronze badges. Shouldn't this be the best solution?
Why aren't many up-voting this? Maybe because other people don't have the same opinion as you? DoWill: Because adding an other 3rd-party library to your executable environment is not always worthwhile. LarsH But Apache Commons, as it is populate, had already included in many many projects already.
It would not be adding yet another 3rd party library for partially string slicing. Show 1 more comment. Interesting alternative, though I can't imagine ever using it, given the more traditional approaches, that were given four years ago.
Best answer because the input String is read only once, so there's no need to store it in a variable, which makes it possible to embed it neatly.
There's a class of question on SO that sometimes make less than perfect sense, this one is perilously close :- Perhaps you could explain your aversion to using one of the two methods you ruled out. Matt Boehm Matt Boehm 1, 1 1 gold badge 18 18 silver badges 20 20 bronze badges. By the way, if you plan on programming in Java, you should try to memorize most of the API methods for String java.
I've already ruled out substring, at least by itself, as not the answer. You have to either check the size or catch the exception. May I ask why doing either of these would not work in your situation? How is this an answer to the question?
0コメント