Bash script wallpaper randomizer
Why you shouldn't parse ls.
Let's consider ls bad practice, and allow me to introduce a different method to solve your issue all together. Find every file in the directory, /home/user/Pictures/Wallpapers, perform a random sort on it and then grab the first result.
find /home/user/Pictures/Wallpapers -type f | sort -R | head -1
Sort man page
       -R, --random-sort
              shuffle, but group identical keys.  See shuf(1)