1. Most nouns ending in ا (a) or ھ (h) are masculines.
Examples:
joota جوتا (shoe), anda انڈا (egg), naghma نغمہ (song)
2. nouns ending in ی (i) are mostly feminines
Examples:
gari گاڑی (train), sardi سردی (cold)
3. Words taken from arabic and ending in ت (t) are feminine
harkat حرکت (movement), maseebat مصیبت (problem) etc.
Otherwise, gender of all other nouns (like book) should be learnt by heart. The best way to learn gender of nouns is to learn expressions and sentences by heart in which they appear.