This repository was archived by the owner on Mar 29, 2021. It is now read-only.
- Notifications
You must be signed in to change notification settings - Fork0
Pointers for Python. The helps us with pointers in the python language. But, the project is archived.
License
NotificationsYou must be signed in to change notification settings
code-roller/python-pointer-library
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
Pointers for Python
To create a newPointer
:
importptrnum:int=10num_pointer:ptr.Pointer=ptr.Pointer(num)
To get the address and value that the pointer points to:
num_pointer_address:int=num_pointer.getAddress()num_pointer_value:int=num_pointer.getVal()
To perform calculations:
# += and -=num_pointer.increment()num_pointer_value_after_plus_equals:int=num_pointer.getVal()num_pointer.decrement()num_pointer_value_after_minus_equals:int=num_pointer.getVal()# + and -num_pointer.add(10)num_pointer_value_after_plus:int=num_pointer.getVal()num_pointer.sub(15)num_pointer_value_after_minus:int=num_pointer.getVal()# ==, !=, <, >, <= and >=other:int=15other_pointer:ptr.Pointer=ptr.Pointer(other)are_addresses_equal:bool=num_pointer.eqeq(other_pointer)are_addresses_not_equal:bool=num_pointer.ne(other_pointer)are_addresses_greater:bool=num_pointer.gt(other_pointer)are_addresses_less:bool=num_pointer.lt(other_pointer)are_addresses_less_or_equal:bool=num_pointer.lte(other_pointer)are_addresses_greater_or_equal:bool=num_pointer.gte(other_pointer)
Made by these members of the code roller team =D
About
Pointers for Python. The helps us with pointers in the python language. But, the project is archived.
Topics
Resources
License
Uh oh!
There was an error while loading.Please reload this page.
Stars
Watchers
Forks
Packages0
No packages published