def function1(fielda, fieldb): print('fielda: {}, fieldb: {}'.format(fielda, fieldb) def function2(): field1 = 5 field2 = 3 function1(field1, field2) if __name__ == '__main__': function2()result:
Output:fielda: 5, fieldb: 3
The field names don't have to be the same between functions (but they can be as well)