It can take input as argument list and return value. This example calls the fullName method of person, using it on person1: or share your feedback to help us improve. By Richard Blum . eval took 0.20154 seconds. This is a simple example of an user-defined function, that display today's date: Note: A function name must start with a letter or underscore character not with a number, optionally followed by the more letters, numbers, or underscore characters. The function outputs "Hello There may be a situation when you need to import a variable from the main program into a function, or vice versa. Since the data types are not set in a strict sense, you can do things like