Creating an array.array Instance with Two Integers

  • Share this:

Code introduction


Create an array.array instance containing two integers. array.array is a built-in array type in Python that can store basic data types, such as integers.


Technology Stack : array

Code Type : Function

Code Difficulty :


                
                    
def a_func(arg1, arg2):
    import array
    return array.array('i', [arg1, arg2])                
              
Tags: