I am total newbie to programming and python. I was solving a problem. I found the solution but it seems like too slow.
if n % 2 == 0 and n % 3 == 0 and\\
You need a condition that evaluates True when all divisions give a zero remainder. The two solutions so far proposed don't appear to do that. I suspect the condition you need is
if not any(n % i for i in range(2, 21)):