English Deutsch Français Italiano Español Português 繁體中文 Bahasa Indonesia Tiếng Việt ภาษาไทย
All categories

I have 120 audio book files on one CD. My MP3 player allows me to select by directory and then by the file. There are just 2 buttons I can use - next directory, and next file. It does not matter how I divide the files into differenct directories. Currently, I have all 120 files in one directory. This means I have to press a button 12o times to reach the last file. How can I minimise the number of key presses to ANY file?

2007-08-15 12:49:54 · 3 answers · asked by Hearts 1 in Science & Mathematics Mathematics

3 answers

You want to minimize a + b when ab ≥ 120. Basically, that means making a and b as close to the same number as possible. So, have 10 subdirectories with 12 files per directory, or 12 subdirectories with 10 files per directory. Or, I guess, have11 subdirectories with 11 files per directory, giving you room for one more file. In all cases, that means a maximum of 22 key presses.

2007-08-15 12:58:22 · answer #1 · answered by Anonymous · 0 0

Can a subdirectory contain a directory? If so, consider a "binary tree" structure. That is, at the highest level have a directory with 2 subdirectories, each of which contains 2 more subdirectories, etc., until you have a structure 7 levels deep (counting the highest-level directory as level 1). At the lowest level, you will have 64 (= 2^6) directories. Put 2 files in each of the lowest-level directories. In this way you can reach any of up to 128 files in just 7 clicks.

2007-08-15 20:38:19 · answer #2 · answered by jw 3 · 0 0

zanti is right about 11 directories and 11 files/directory.
Are you sure you can't select previous directory? That would be an enormous help. When you reach the last directory, does pressing "NEXT DIRECTORY" take you back to Directory #1? I'd suggest you get an MP3 player that allows you to go directly to a particular directory or at least allows you to go to the previous directory.

2007-08-15 20:17:18 · answer #3 · answered by ironduke8159 7 · 0 0

fedest.com, questions and answers