Binette@lemmy.ml to Learn Programming@programming.devEnglish · 2 years agoIs it better to check if a file exists before trying to load it, or to try to load it, and catch the error and move on?message-squaremessage-square16linkfedilinkarrow-up138arrow-down10file-text
arrow-up138arrow-down1message-squareIs it better to check if a file exists before trying to load it, or to try to load it, and catch the error and move on?Binette@lemmy.ml to Learn Programming@programming.devEnglish · 2 years agomessage-square16linkfedilinkfile-text
I would use both.