Sane cyclists don't ride 20 on the sidewalk. Too many obstacles and too much risk. Any alley/driveway is potentially a blind corner with a car backing out. Pedestrians never move predictably. Etc, etc.
Bike lanes are hit or miss. I'd ride over 20 in a protected lane, but not next to a line of parked cars (door zone).
How? 20mph for a road bike is slower than what trained cyclists do