Solving jumbled letters using a given dictionary Given a dictionary, a method to do lookup in dictionary and a M x N board where every cell has one character. Find all possible words that can be formed by a sequence of adjacent characters.
Example:

Input: dictionary[] = {"GEEKS", "FOR", "QUIZ", "GO"}; 
       boggle[][]   = {{'G','I','Z'},  
                       {'U','E','K'},  
                       {'Q','S','E'}};

Output:  Following words of dictionary are present  
         GEEKS, QUIZ


Below is my code:  

dictSize=int(raw_input())
dictionary=raw_input().split(' ')
m,n=map(int,raw_input().split(' '))
boggle=[[0 for x in range(n)] for y in range(m)]
#print dictionary

bString=raw_input().split()
for i in range(0,m):
    for j in range(0,n):
        boggle[i][j]=bString[(i*n)+j]
#print boggle


lookUp={}
for i in range(0,m):
    for j in range(0,n):
        lookUp[boggle[i][j]]=lookUp.get(boggle[i][j],0)+1

possibility=[]
flag=0
for i in range(0,len(dictionary)):
    for s in dictionary[i]:
        if(lookUp.has_key(s)):
            flag=0
        else:
            flag=1
    if(flag==0):
        possibility.append(dictionary[i])
#print possibility

for i in range(0,len(possibility)):
    print possibility[i],
Loop like a native

I highly recommend Ned Batchelder's excellent talk called "Loop like a native".

for i in range(0,len(possibility)):
    print possibility[i],


can be rewritten:

for p in possibility:
    print p,


Python 2 in 2018

It is probably a bad idea to write new Python 2 code in 2018. You should try to write it in Python 3.