It's not a secret anymore!*
The moose likes Cattle Drive and the fly likes Style Guide Question Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » This Site » Cattle Drive
Bookmark "Style Guide Question" Watch "Style Guide Question" New topic
Author

Style Guide Question

Mike Cunningham
Ranch Hand

Joined: Nov 14, 2000
Posts: 129
I've been looking over the Style Guide section 2.2 - Spacing. I cannot locate the problem with spacing in my reviewed code below. Please help. Thanks.
________________________________________________________
String theName = ( args[0] + " " );
int printsPerLine = 79 / ( theName.length() );
int totalFullLines = 100 / printsPerLine;
spacing around all identifiers.
int lastLinePrints = 100 % printsPerLine;
spacing here also.
Amber Woods
Ranch Hand

Joined: Mar 28, 2001
Posts: 111
Hey Mike,
I still get that response every so often.
spacing around all identifiers means before and After the identifiers.
For example: x = y + z ;
Amber
[This message has been edited by Amber Woods (edited May 15, 2001).]


"Happiness is a way to Travel, <b>Not</b> a Destination" -- Unknown
Joel Cochran
Ranch Hand

Joined: Mar 23, 2001
Posts: 301
The only hint I can give is that you only have a "quasi" (partial...think half...) problem, and it the same on each statement line.

------------------
I'm a soldier in the NetScape Wars...
Joel


Wait a minute, I'm trying to think of something clever to say...<p>Joel
Mike Cunningham
Ranch Hand

Joined: Nov 14, 2000
Posts: 129
Okay, I see it now. That will be a hard one to adjust to.
Thanks for the hints!
- Mike
Johannes de Jong
tumbleweed
Bartender

Joined: Jan 27, 2001
Posts: 5089
Dont worry Mike you will get used to it
Good luck
Peter Gragert
Ranch Hand

Joined: Jan 16, 2001
Posts: 424
int totalFullLines = 100 / printsPerLine;
int totalFullLines = 100 / printsPerLine"here a space too! ;-) ";
Try to find an editor or IDE which does this kind of stuff
automatically!
Until now I have a 95% solution of this kind of problem by
using the IDE of Together ( University licence ) where I can
manage the style of beautifying.

[This message has been edited by Peter Gragert (edited May 17, 2001).]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Style Guide Question