import os
mypath = raw_input("Please inmput directory to create:");
if not len(mypath):
print 'Error: no path specified => exit!'
quit();
for c in mypath:
if ord(c) > 127:
print 'Can not create dir with Chinese';
quit();
try:
os.mkdir(mypath)
except:
print 'Directory creation failure! => exit!'
quit();
print 'Create dir %s successfully!' %(mypath);
mypath = raw_input("Please inmput directory to create:");
if not len(mypath):
print 'Error: no path specified => exit!'
quit();
for c in mypath:
if ord(c) > 127:
print 'Can not create dir with Chinese';
quit();
try:
os.mkdir(mypath)
except:
print 'Directory creation failure! => exit!'
quit();
print 'Create dir %s successfully!' %(mypath);