Vrundesha Joshi has Published 343 Articles

multiset insert() function in C++ STL

Vrundesha Joshi

Vrundesha Joshi

Updated on 30-Jul-2019 22:30:25

145 Views

The multiset insert() function in C++ STL which insert elements in the multiset container from a position to another position from one multiset to a different multiset.List of functions used:ms.size() = Returns the size of multiset. ms.insert() = It is used to insert elements to the multiset.Example Code#include #include ... Read More

C++ Program to Implement Quick Sort Using Randomization

Vrundesha Joshi

Vrundesha Joshi

Updated on 30-Jul-2019 22:30:25

3K+ Views

The quicksort technique is done by separating the list into two parts. Initially a pivot element is chosen by partitioning algorithm. The left part of the pivot holds the smaller values than pivot, and right part holds the larger value. After partitioning, each separate lists are partitioned using same procedure.In ... Read More

How to get programmatically android build id?

Vrundesha Joshi

Vrundesha Joshi

Updated on 30-Jul-2019 22:30:25

528 Views

This example demonstrate about How to get programmatically android build id.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 ... Read More

C++ Program to Implement Graph Structured Stack

Vrundesha Joshi

Vrundesha Joshi

Updated on 30-Jul-2019 22:30:25

406 Views

In this C++ program we implement Graph Structured Stack.AlgorithmBegin    Function graphStructuredStack(int **adjMat, int s, int bNode):    Take an array adjMat, source s and bottom node bNode    initialize stackFound = false    for sVertex = 1 to noOfNodes       for dVertex = 1 to noOfNodes   ... Read More

How to binarySearch in android listview?

Vrundesha Joshi

Vrundesha Joshi

Updated on 30-Jul-2019 22:30:25

248 Views

This example demonstrates How to binarySearch 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.               ... Read More

C++ Program to Implement Bit Array

Vrundesha Joshi

Vrundesha Joshi

Updated on 30-Jul-2019 22:30:25

2K+ Views

This is a C++ program to implement Bit Array. A Bit Array is an array data structures that compactly stores data. It is basically used to implement a simple data structure.AlgorithmFunctions and pseudocodes:Begin    Function getBit(int val, int pos)    singleBit->b = 0    if(pos == 0)       ... Read More

How to move the pointer of a ResultSet to the default position using JDBC?

Vrundesha Joshi

Vrundesha Joshi

Updated on 30-Jul-2019 22:30:25

455 Views

The beofreFirst() method of the ResultSet interface moves the cursor/pointer to its default position i.e. before the first record.rs.beforeFirst();Assume we have a table named cricketers_data with 6 records as shown below:+----+------------+------------+---------------+----------------+-------------+ | ID | First_Name | Last_Name  | Year_Of_Birth | Place_Of_Birth | Country     | +----+------------+------------+---------------+----------------+-------------+ | 1 | ... Read More

C++ Program to Implement Merge Sort Algorithm on Linked List

Vrundesha Joshi

Vrundesha Joshi

Updated on 30-Jul-2019 22:30:25

1K+ Views

The merge sort technique is based on divide and conquer technique. We divide the while data set into smaller parts and merge them into a larger piece in sorted order. It is also very effective for worst cases because this algorithm has lower time complexity for worst case also.Linked list ... Read More

How to Count Occurrences of Each Character in String in Android?

Vrundesha Joshi

Vrundesha Joshi

Updated on 30-Jul-2019 22:30:25

384 Views

This example demonstrates How to Count Occurrences of Each Character in String 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.     ... Read More

How to get the current value of a particular row from a database using JDBC?

Vrundesha Joshi

Vrundesha Joshi

Updated on 30-Jul-2019 22:30:25

1K+ Views

The refreshRow() method of the ResultSet interface refreshes the current row with the most recent value in the database.rs.refreshRow()Assume we have a table named cricketers_data with 7 records as shown below:+----+------------+------------+---------------+----------------+-------------+ | ID | First_Name | Last_Name  | Year_Of_Birth | Place_Of_Birth | Country     | +----+------------+------------+---------------+----------------+-------------+ | 1  | ... Read More

Advertisements