Among Python’s built-in types, list, tuple and dict are known as container data types. The collection module provides some more specialized alternatives to built-in types by improvising them. The Counter class is subclassed from built-in dict class. Object of Count class is a key-value pair. Key is an element in sequence or dicrionary and value is count of its occurences. Empty Counte.....
The string module in Python’s standard library provides following useful constants, classes and a helper function called capwords() ascii_lettersThe concatenation of lowercase and uppercase constants.ascii_lowercaseThe lowercase letters 'abcdefghijklmnopqrstuvwxyz'ascii_uppercaseThe uppercase letters 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'digitsThe string '0123456789'.hexdigitsThe string '012345.....
The zipapp module has been introduced in Python's standard library since ver 3.5. This module is used to manage the creation of zip files containing Python code, which can be executed directly by the Python interpreter. The module provides both a Command-Line Interface and a programming interface. To use zipapp module programmatically, we should have a module in which main function is prese.....
Functions in the platform module help us probe the underlying platform’s hardware, operating system, and interpreter version information. This function queries the given executable (defaults to the Python interpreter executable) for various architecture information. , This function returns the machine type, e.g. 'i386'. An empty string is returned if the value cannot be determined. , .....
Reservation protocols are the class of protocols in which the stations wishing to transmit data broadcast themselves before actual transmission. These protocols operate in the medium access control (MAC) layer and transport layer of the OSI model. In these protocols, there is a contention period prior to transmission. In the contention period, each station broadcasts its desire for transmis.....
In computer networks, when more than one station tries to transmit simultaneously via a shared channel, the transmitted data is garbled. This event is called collision. The Medium Access Control (MAC) layer of the OSI model is responsible for handling collision of frames. Collision – free protocols are devised so that collisions do not occur. Protocols like CSMA/CD and CSMA/CA nullifi.....
This example demonstrate about How to reverse of integer array in android listview. Step 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill all required details to create a new project. Step 2 − Add the following code to res/layout/activity_main.xml , In the code, we have taken listview to show reversed array Step 3 − Add the following .....
This example demonstrate about How to print exception messages in android. Step 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill all required details to create a new project. Step 2 − Add the following code to res/layout/activity_main.xml. , In the above code, we have taken textview to show exception message. Step 3 − Add the following cod.....
This example demonstrate about How to insert integer array in android listview. Step 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill all required details to create a new project. Step 2 − Add the following code to res/layout/activity_main.xml , In the code, we have taken listview to show integer array. Step 3 − Add the following code.....
This example demonstrate about How to check existence of an element in android listview. Step 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill all required details to create a new project. , In the above code, we have taken editext, button and listview. When user click on button after inserting value in edittext,it will do data validation with listvie.....
Sign up now to get your own personalized profile!
We use cookies to provide and improve our services. By using our site, you consent to our Cookies Policy. Accept Learn more