Nitya Raut has Published 276 Articles

Print a character n times without using loop, recursion or goto in C++

Nitya Raut

Nitya Raut

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

837 Views

In this section we will see how to print a character n times without using loops and recursion in C++. We can solve this problem by using string class constructors. There is a constructor where we are taking the character that will be printed multiple times, and the number of ... Read More

reference_wrapper in C++

Nitya Raut

Nitya Raut

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

209 Views

In C++ the reference_wrapper is a class template that helps by wrapping a reference in a copy constructible and copy assignable object of type T. The instances of std::reference_wrapper are basically objects, but they can be converted into T&. So we can use as argument with the functions that take ... Read More

How to share intent from intentservice in android?

Nitya Raut

Nitya Raut

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

295 Views

Before getting into example, we should know what Intent service is in android. Intent Service is going to do back ground operation asynchronously. When user call startService() from activity , it doesn’t create instance for each request. It going to stop service after done some action in service class or ... Read More

How to add a new column to an existing table using JDBC API?

Nitya Raut

Nitya Raut

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

2K+ Views

You can add a new column to a table using the ALTER TABLE command.SyntaxALTER TABLE table_name ADD column_name datatype;Assume we have a table named Sales in the database with 5 columns namely ProductName, CustomerName, DispatchDate, DeliveryTime, Price and, Location as shown below:+-------------+--------------+--------------+--------------+-------+----------------+ | ProductName | CustomerName | DispatchDate | DeliveryTime ... Read More

Data Analysis and Visualization in Python?

Nitya Raut

Nitya Raut

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

1K+ Views

Python provides numerous libraries for data analysis and visualization mainly numpy, pandas, matplotlib, seaborn etc. In this section, we are going to discuss pandas library for data analysis and visualization which is an open source library built on top of numpy.It allows us to do fast analysis and data cleaning ... Read More

Creating multiple process using fork() in C

Nitya Raut

Nitya Raut

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

1K+ Views

In this section we will see how to use the fork() to make child process in C. We also do some different tasks in each process. So in our parent process we will print different values.When fork() is called, it returns a value. If the value is greater than 0, ... Read More

Calculation in parent and child process using fork() in C++

Nitya Raut

Nitya Raut

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

2K+ Views

In this section we will see how to use the fork() to make child process in C++. We also do some calculation into each process. So in our parent process we will find sum of all even numbers of an array, and inside the child process we will count the ... Read More

Get clicked item and its position in RecyclerView?

Nitya Raut

Nitya Raut

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

3K+ Views

This example demonstrate about how to get clicked item and its position in RecyclerViewStep 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

Chrono library in C++

Nitya Raut

Nitya Raut

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

567 Views

In this section we will see what is the Chrono library in C++. This Chrono library is used for date and time. Timers and clocks are different in different systems. So if we want to improve time over precision we can use this library.In this library, it provides precision-neutral concept, ... Read More

How can I make my custom objects Serializable?

Nitya Raut

Nitya Raut

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

193 Views

This example demonstrate about how can I make my custom objects SerializableStep 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

Advertisements