Tuesday, December 25, 2012

Java Exercise #97: Determine Directory Size

Exercise: Use recursion to write a program that will determine the size of a given directory.


Enter a file or directory: C:\Users\Maya\Favorites
17711 bytes.

Enter a file or directory: C:\Users\Maya\Desktop\aneesh\Java Exercises\Bouncing Ball.png
26651 bytes.

Enter a file or directory: C:\Users\Maya\Desktop\aneesh\Java Exercises\No File.txt
0 bytes.


Download Code: Directory Size

No comments:

Post a Comment