
Data Structure
Networking
RDBMS
Operating System
Java
MS Excel
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
Anvi Jain has Published 569 Articles

Anvi Jain
246 Views
Before getting into example, we should know what sqlite data base in android is. SQLite is an open source SQL database that stores data to a text file on a device. Android comes in with built in SQLite database implementation. SQLite supports all the relational database features. In order to ... Read More

Anvi Jain
1K+ Views
To calculate a value from multiple columns, use GROUP BY. Following is the syntax −select yourColumnName1, sum(yourColumnName2*yourColumnName3) AS anyAliasName from yourTableName group by yourColumnName1;Let us first create a table −mysql> create table calculateValueDemo -> ( -> Id int, -> ProductPrice int, -> ProductWeight int -> ... Read More

Anvi Jain
580 Views
You can return a specific field from collection.find() by using the following syntax.Case 1 − The syntax is as follows −db.yourCollectionName.find({}, {"yourFieldName":1}).pretty();The above field name is set to 1 means it will return only that field. If you set to 0 it will return all fields except the field which ... Read More

Anvi Jain
902 Views
If a directed graph is given, determine if a vertex j is reachable from another vertex i for all vertex pairs (i, j) in the given graph. Reachable mean that there is a path from vertex i to j. This reach-ability matrix is called transitive closure of a graph. Warshall ... Read More

Anvi Jain
374 Views
The CAST() function in MySQL converts a value of any type into a value that has a specified type. Let us first create a table −mysql> create table castFunctionDemo -> ( -> ShippingDate date -> ); Query OK, 0 rows affected (0.74 sec)Following is the query to ... Read More

Anvi Jain
1K+ Views
Here is a C++ Program to Implement Traveling Salesman Problem using Nearest Neighbour Algorithm.Required functions and pseudocodesAlgorithmBegin Initialize c = 0, cost = 1000; Initialize g[][]. function swap() is used to swap two values x and y. function cal_sum() to calculate the cost which take array ... Read More

Anvi Jain
748 Views
To format MySQL time with lowercase am/pm, use the LOWER() as well as DATE_FORMAT().Let us first create a table −mysql> create table formatTime -> ( -> LoginTime time -> ); Query OK, 0 rows affected (0.56 sec)Following is the query to insert records in the table using ... Read More

Anvi Jain
2K+ Views
AVL tree is a self-balancing Binary Search Tree where the difference between heights of left and right subtrees cannot be more than one for all nodes.This is a C++ program to check if a given Binary Tree is an AVL Tree or not.AlgorithmBegin function AVL() returns true if the given ... Read More

Anvi Jain
96 Views
To reorder integer except for value 0, use the below syntax −select *from yourTableName order by yourColumnName=0 ,yourColumnName;Let us first create a table −mysql> create table reorderIntegerExcept0 -> ( -> value int -> ); Query OK, 0 rows affected (0.70 sec)Following is the query to insert records ... Read More

Anvi Jain
4K+ Views
Let us see how to generate different random numbers using C++. Here we are generating random numbers in range 0 to some value. (In this program the max value is 100).To perform this operation we are using the srand() function. This is in the C++ library. The function void srand(unsigned ... Read More