Nitya Raut has Published 221 Articles

Flexible Array Members in a structure in C

Nitya Raut

Nitya Raut

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

1K+ Views

Flexible Array members in a structure in C means we can declare array without its dimension within a structure and its size will be flexible in nature. Flexible array member must be the last member of class.Here is an example:Example#include #include #include //structure of type employee and must contain at ... Read More

Calculate distance and duration between two places using google distance matrix API in Python?

Nitya Raut

Nitya Raut

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

804 Views

We almost all use google maps to check distance between source and destination and check the travel time. For developers and enthusiasts, google provide ‘google distance matrix API’ to calculate the distance and duration between two places.To use google distance matrix api, we need google maps API keys, which you ... Read More

How to get android application last update information?

Nitya Raut

Nitya Raut

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

350 Views

This example demonstrate about How to get android application last update information.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 ... Read More

An Uncommon representation of array elements in C/C++

Nitya Raut

Nitya Raut

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

127 Views

This is a simple C++ program of an uncommon representation of array elements.#include using namespace std; int main() { int array[5] = {7,7,7, 6, 6}; for (int i = 0; i < 5; i++) cout

C program to copy string without using strcpy() function

Nitya Raut

Nitya Raut

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

605 Views

In this section we will see how to copy a string to other string without using strcpy() function. To solve this problem we can write our own function that can act like strcpy(), but here we will follow some trick. We will use another library function to copy a string ... Read More

How to add webview focus in android?

Nitya Raut

Nitya Raut

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

1K+ Views

This example demonstrate about How to add webview focus 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 ... Read More

How to save data with syntax without Content Values in Android sqlite?

Nitya Raut

Nitya Raut

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

327 Views

Before getting into example, we should know what sqlite data base in android is. SQLite is an opensource 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 access ... Read More

How to drop a database using JDBC API?

Nitya Raut

Nitya Raut

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

361 Views

A. You can drop/delete a database using the DROP DATABASE query.SyntaxDROP DATABASE DatabaseName;To drop a Database using JDBC API you need to:Register the driver: Register the driver class using the registerDriver() method of the DriverManager class. Pass the driver class name to it, as parameter.Establish a connection: Connect ot the ... Read More

Switch case statement in C

Nitya Raut

Nitya Raut

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

1K+ Views

A switch statement allows a variable to be tested for equality against a list of values. Each value is called a case, and the variable being switched on is checked for each switch case.The syntax for a switch statement in C programming language is as follows −switch(expression) {    case ... Read More

urllib.parse — Parse URLs into components in Python

Nitya Raut

Nitya Raut

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

8K+ Views

This module provides a standard interface to break Uniform Resource Locator (URL) strings in components or to combine the components back into a URL string. It also has functions to convert a "relative URL" to an absolute URL given a "base URL."This module supports the following URL schemes -fileftpgopherhdlhttphttpsimapmailtommsnewsnntpprosperorsyncrtsprtspusftpshttpsipsipssnewssvnsvn+sshtelnetwaiswswssurlparse()This function ... Read More

Advertisements