Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.java.programmer > #26657
| X-Received | by 10.50.23.84 with SMTP id k20mr1873074igf.1.1385689551858; Thu, 28 Nov 2013 17:45:51 -0800 (PST) |
|---|---|
| X-Received | by 10.49.101.73 with SMTP id fe9mr1177011qeb.6.1385689551824; Thu, 28 Nov 2013 17:45:51 -0800 (PST) |
| Path | csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!news.glorb.com!p15no1745212qaj.0!news-out.google.com!p7ni3166qat.0!nntp.google.com!p15no1745209qaj.0!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail |
| Newsgroups | comp.lang.java.programmer |
| Date | Thu, 28 Nov 2013 17:45:51 -0800 (PST) |
| In-Reply-To | <2dd11538-00b2-42e0-8ddf-bdb6263478b4@googlegroups.com> |
| Complaints-To | groups-abuse@google.com |
| Injection-Info | glegroupsg2000goo.googlegroups.com; posting-host=90.211.251.153; posting-account=sZfD4AoAAAARhYNuj4BQB7GemP5kMqpa |
| NNTP-Posting-Host | 90.211.251.153 |
| References | <bd7dee67.0408241759.3884e4e9@posting.google.com> <4wTWc.18629$cx.18110@bignews4.bellsouth.net> <llWWc.228978$eM2.215971@attbi_s51> <ecaee893-0ad6-48a6-b345-24a33436b4df@googlegroups.com> <mgl879dhdkql5i04bdaisghtkua8hvmq54@4ax.com> <c8f279f7-226f-42b6-8483-e9ce613ba353@googlegroups.com> <2dd11538-00b2-42e0-8ddf-bdb6263478b4@googlegroups.com> |
| User-Agent | G2/1.0 |
| MIME-Version | 1.0 |
| Message-ID | <4dfd478f-58ef-4317-a313-7cddfa16d4b0@googlegroups.com> (permalink) |
| Subject | Re: PRINTING DIAMOND SHAPE WITH LOOPS! |
| From | pchristor@yahoo.co.uk |
| Injection-Date | Fri, 29 Nov 2013 01:45:51 +0000 |
| Content-Type | text/plain; charset=ISO-8859-1 |
| Xref | csiph.com comp.lang.java.programmer:26657 |
Show key headers only | View raw
On Wednesday, 27 November 2013 23:57:07 UTC, Lew wrote:
> pchr...@yahoo.co.uk wrote:
>
> > Here is another option:
>
> >
>
> > public static void main(String[] args) {
>
> >
>
> > int x=9;
>
> > int m=x/2;
>
> > StringBuilder str1= new StringBuilder(x);
>
> > for(int i=0; i<m; i++){str1.append(" ");}
>
> > str1.append("*");
>
> > System.out.println(str1.toString());
>
> > for(int j=1; j<x; j++){
>
> > if(j<=m){ str1.deleteCharAt(m-j);
>
> > str1.append("**");
>
> > }else{
>
> > str1.delete(m,m+2 ); str1.insert(0, " ");
>
> > }
>
> > System.out.println(str1.toString());
>
> > }
>
> > }
>
>
>
> Seriously, dude?
>
>
>
> Start by following the coding conventions, please.
>
>
>
> Then we can help with the logic, should we be so bold.
>
>
>
> --
>
> Lew
What coding conventions are not being followed?
Back to comp.lang.java.programmer | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Re: PRINTING DIAMOND SHAPE WITH LOOPS! jyothi.m1089@gmail.com - 2013-11-01 01:30 -0700
Re: PRINTING DIAMOND SHAPE WITH LOOPS! rossum <rossum48@coldmail.com> - 2013-11-01 13:03 +0000
Re: PRINTING DIAMOND SHAPE WITH LOOPS! Mike Amling <mamling@chaff.us> - 2013-11-01 09:59 -0500
Re: PRINTING DIAMOND SHAPE WITH LOOPS! Roedy Green <see_website@mindprod.com.invalid> - 2013-11-01 18:32 -0700
Re: PRINTING DIAMOND SHAPE WITH LOOPS! pchristor@yahoo.co.uk - 2013-11-12 05:21 -0800
Re: PRINTING DIAMOND SHAPE WITH LOOPS! Lew <lewbloch@gmail.com> - 2013-11-27 15:57 -0800
Re: PRINTING DIAMOND SHAPE WITH LOOPS! Arne Vajhøj <arne@vajhoej.dk> - 2013-11-27 19:21 -0500
Re: PRINTING DIAMOND SHAPE WITH LOOPS! pchristor@yahoo.co.uk - 2013-11-28 17:45 -0800
Re: PRINTING DIAMOND SHAPE WITH LOOPS! Arne Vajhøj <arne@vajhoej.dk> - 2013-11-28 21:10 -0500
Re: PRINTING DIAMOND SHAPE WITH LOOPS! pchristor@yahoo.co.uk - 2013-11-29 03:03 -0800
Re: PRINTING DIAMOND SHAPE WITH LOOPS! Joerg Meier <joergmmeier@arcor.de> - 2013-11-29 12:33 +0100
Re: PRINTING DIAMOND SHAPE WITH LOOPS! pchristor@yahoo.co.uk - 2013-11-29 09:01 -0800
Re: PRINTING DIAMOND SHAPE WITH LOOPS! Arne Vajhøj <arne@vajhoej.dk> - 2013-11-29 13:15 -0500
Re: PRINTING DIAMOND SHAPE WITH LOOPS! pchristor@yahoo.co.uk - 2013-11-29 17:06 -0800
Re: PRINTING DIAMOND SHAPE WITH LOOPS! pchristor@yahoo.co.uk - 2013-11-29 17:24 -0800
Re: PRINTING DIAMOND SHAPE WITH LOOPS! Arne Vajhøj <arne@vajhoej.dk> - 2013-11-29 20:59 -0500
Re: PRINTING DIAMOND SHAPE WITH LOOPS! pchristor@yahoo.co.uk - 2013-11-30 06:57 -0800
Re: PRINTING DIAMOND SHAPE WITH LOOPS! Arne Vajhøj <arne@vajhoej.dk> - 2013-11-30 10:31 -0500
Re: PRINTING DIAMOND SHAPE WITH LOOPS! Lew <lewbloch@gmail.com> - 2013-12-02 15:32 -0800
Re: PRINTING DIAMOND SHAPE WITH LOOPS! pchristor@yahoo.co.uk - 2013-12-04 03:45 -0800
Re: PRINTING DIAMOND SHAPE WITH LOOPS! Arne Vajhøj <arne@vajhoej.dk> - 2013-12-09 21:10 -0500
Re: PRINTING DIAMOND SHAPE WITH LOOPS! pchristor@yahoo.co.uk - 2013-12-05 00:15 -0800
Re: PRINTING DIAMOND SHAPE WITH LOOPS! Arne Vajhøj <arne@vajhoej.dk> - 2013-12-09 21:14 -0500
Re: PRINTING DIAMOND SHAPE WITH LOOPS! Joerg Meier <joergmmeier@arcor.de> - 2013-11-29 19:58 +0100
Re: PRINTING DIAMOND SHAPE WITH LOOPS! pchristor@yahoo.co.uk - 2013-11-29 17:12 -0800
Re: PRINTING DIAMOND SHAPE WITH LOOPS! Joerg Meier <joergmmeier@arcor.de> - 2013-11-30 02:55 +0100
Re: PRINTING DIAMOND SHAPE WITH LOOPS! Arne Vajhøj <arne@vajhoej.dk> - 2013-11-29 21:01 -0500
Re: PRINTING DIAMOND SHAPE WITH LOOPS! Lew <lewbloch@gmail.com> - 2013-12-02 15:31 -0800
Re: PRINTING DIAMOND SHAPE WITH LOOPS! Arne Vajhøj <arne@vajhoej.dk> - 2013-11-29 12:48 -0500
csiph-web