No more Blub for me, thank you, Vicar.
chris webster wrote:Can anyone write the program? Sure.
harikrishnan venkatesan wrote:i need this program output.. like this..
"Leadership is nature's way of removing morons from the productive flow" - Dogbert
Articles by Winston can be found here
harikrishnan venkatesan wrote:n = 5 (like we get any number )
it contains 01234........
harikrishnan venkatesan wrote:
i need output like this under below..
0123
0124
1234
2340
3401
There are only two hard things in computer science: cache invalidation, naming things, and off-by-one errors
fred rosenberger wrote:If you need those five literal outputs, just do 5 "System.out.println()" statements, with those literals.
"Il y a peu de choses qui me soient impossibles..."
Stevens Miller wrote:I would at least suggest he look up the "modulus" operator (implemented in Java, C, C++, and every other language in the current family that quietly copies C's basic syntax, with the "%" character). That ought to give you a lead on at least one way to compute your result.
"Leadership is nature's way of removing morons from the productive flow" - Dogbert
Articles by Winston can be found here
Winston Gutkowski wrote:
Stevens Miller wrote:I would at least suggest he look up the "modulus" operator...
Are you a teacher perchance?
"Il y a peu de choses qui me soient impossibles..."
Stevens Miller wrote:Hardly. I'm everyone's worst nightmare come true: an American lawyer who writes computer programs...
"Leadership is nature's way of removing morons from the productive flow" - Dogbert
Articles by Winston can be found here
Stevens Miller wrote:Yourself?
"Leadership is nature's way of removing morons from the productive flow" - Dogbert
Articles by Winston can be found here
Stevens Miller wrote:, fred. I went to college with a guy who took a final exam including a question calling for code to print the first ten rows of Pascal's triangle. He used your method, since his programming skills had never been very good. Being a last-semester senior, failure meant quite a bit. A couple of us went to bat for him and the professor grudgingly gave him credit for it, since the question called for a program that would "print" the result, not necessarily "compute" it.
There are only two hard things in computer science: cache invalidation, naming things, and off-by-one errors
fred rosenberger wrote:I am hoping the OP can come back and tell us what they really want.
fred rosenberger wrote:My wife, an American Lawyer, made up business cards for me that say "Fred Rosenberger - Didactic Literalist"
"Leadership is nature's way of removing morons from the productive flow" - Dogbert
Articles by Winston can be found here
Winston Gutkowski wrote:
Stevens Miller wrote:Hardly. I'm everyone's worst nightmare come true: an American lawyer who writes computer programs...
Aaargh. Law And Coder. I can see it on NBC's 2014 lineup already....
Winston Gutkowski wrote:35-year vet with fairly standard COBOL→PL/1→C→C++→Java progression - with a few funky stops and sidelines in between.
Winston Gutkowski wrote:So, pretty boring by comparison.
"Il y a peu de choses qui me soient impossibles..."
Stevens Miller wrote:I'm everyone's worst nightmare come true: an American lawyer who writes computer programs.
Paul Clapham wrote:
Stevens Miller wrote:I'm everyone's worst nightmare come true: an American lawyer who writes computer programs.
So the rest of us get to make up half-baked legal theories and suffix them with "IANAL", but you can't do that.
"Il y a peu de choses qui me soient impossibles..."
Seriously? That's what you're going with? I prefer this tiny ad:
Gift giving made easy with the permaculture playing cards
https://coderanch.com/t/777758/Gift-giving-easy-permaculture-playing
|