Answer / chaitu
# import modules used here -- sys is a very standard one
# Gather our code in a main() function
print 'Hello', sys.argv
# Command line args are in sys.argv, sys.argv ...
# sys.argv is the script name itself and can be ignored
# Standard boilerplate to call the main() function to begin
# the program.
if __name__ == '__main__':
Running this program from the command line looks like:
$ python hello.py User
|Is This Answer Correct ?||0 Yes||0 No|
Write a python program to swap the first and last value of a list?
Write a python program to print table of a given number?
Can you write a program to find the average of numbers in a list in python?
How do you set a global variable inside a function?
plz tell me the exam date for clerks in sbi
Write a python program to check if a string is a palindrome or not?
Write a python program to check if a number is a perfect number?
Write a python program to find the second largest number in a list?
How to print sum of the numbers starting from 1 to 100?
Write a program to find sum of the digits of a number in python?
Write a function that takes as input a binary tree, and prints out each level of the tree on a newline. For example: a / b c / / d e f will output: a b c d e f
Discuss an algorithm to traverse a tree, depth first.