EvilZone

Programming and Scripting => Java => : Kulverstukas September 12, 2011, 12:51:26 PM

: [Java] CountMyFiles
: Kulverstukas September 12, 2011, 12:51:26 PM
Ok, another version of "CountMyFiles". I've written it in Pascal, Delphi, Python and now Java :D
Nice little project to get you started on the language.

Code: http://newage.ql.lt/projects/java/CountMyFiles.java (http://newage.ql.lt/projects/java/CountMyFiles.java)

Usage:
javac CountMyFiles.java
java CountMyFiles PATH files/folders
: Re: [Java] CountMyFiles
: petermlm September 12, 2011, 01:16:40 PM
I've written it in Pascal, Delphi, Python and now Java :D

That is great! Do you use any method to port the codes or do you write every thing from scratch?
: Re: [Java] CountMyFiles
: Kulverstukas September 12, 2011, 02:05:53 PM
That is great! Do you use any method to port the codes or do you write every thing from scratch?
Wouldn't be much of a learning if I were to just port codes... I just have the idea how it should work and I write it from scratch.
: Re: [Java] CountMyFiles
: petermlm September 12, 2011, 02:11:27 PM
Wouldn't be much of a learning if I were to just port codes... I just have the idea how it should work and I write it from scratch.

I thought as must, lol.
: Re: [Java] CountMyFiles
: xor September 12, 2011, 02:18:58 PM
Tip #1: Don't let your lines go over 80 characters wide.
Tip #2: Don't break up your functions using //================ use 2-3 carriage returns
Tip #3: Functions should start with a lower case letter and capitalize the first letter of each word.
Tip #4: package names should ALWAYS be in lower case.
Tip #5: Class names should be more about what it does rather than what your program is, for example. CountMyFiles becomes FileCounter.
Tip #6: I could think of more, but you're talking to me on the IRC and I'm intrigued...