Yes, the perfect pokemon has usually 31 IVs in all stats (except gyro ball users, which usually carry 0 in speed to increase damage, and other minor exceptions), but as you said the chances of finding perfect IVs are remote so you just conform with whatever you got (unless you know what you are doing and you want to spend a good time breeding).EVs are normally farmed. Usually you want to get 252 EVs in the two most important stats of your pokemon. For beginners, offensive pokemon usually carry 252 in speed and one of the attack stats, while defensive pokemon use 252 in hp and one of the defenses. There are some items, called the power items (power band, lens, anklet, belt, weight and another one I don' remember now). You can buy on the third or fourth (not sure) floor of the dept store and make the pokemon it has the item get EVs faster. 4 EVs of the type of the item per pokemon killed plus the original EVs the pokemon gave. Then you go to peridot and kill as many Grimmers or Noibats you need (Grimmers give health, Noibats give speed) to get your perfect EVs. It's tedious but you'll notice it, especially on speed.
As a last advice, take 5 pokemon with pickup with you while you farm EVs, you'll get lots of useful things.