How do you describe the size of a file?
A file size is the measure of space a file takes up on a storage medium, such as a computer hard drive. File sizes can be measured in bytes (B), kilobytes (KB), megabytes (MB), gigabytes (GB), terabytes (TB), and beyond.
How to check the size of a file in Java?
Java get file size using File class
Java File length() method returns the file size in bytes. The return value is unspecified if this file denotes a directory.