George John has Published 1167 Articles

Complex numbers in C++

George John

George John

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

8K+ Views

In this section we will see how to create and use complex numbers in C++. We can create complex number class in C++, that can hold the real and imaginary part of the complex number as member elements. There will be some member functions that are used to handle this ... Read More

C++ Array of Strings

George John

George John

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

18K+ Views

In this section we will see how to define an array of strings in C++. As we know that in C, there was no strings. We have to create strings using character array. So to make some array of strings, we have to make a 2-dimentional array of characters. Each ... Read More

Extract the user ID from the username only in MySQL?

George John

George John

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

1K+ Views

To extract the User ID only from MySQL, you can use SUBSTRING_INDEX(), which extracts the part of a string from the Username to get the User ID. Let us first display the user −mysql> SELECT USER();This will produce the following output −+----------------+ | USER() ... Read More

Why does the order in which libraries are linked sometimes cause errors in GCC?

George John

George John

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

114 Views

Basically this kind of errors are originated from the linker in the compilation phase. The default behavior of a linker is to take the code from archive libraries when the current program needs it.To work properly the libraries must be present in order. We can say that it must be ... Read More

How to restart MySQL server?

George John

George John

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

1K+ Views

Restart the MySQL Server with the help of restart command.The syntax is as followsRestartLet us first check the MySQL version.The query is as followsSELECT version();Now, implement the above command in order to restart the MySQL Server.The query is as followsmysql> restart; Query OK, 0 rows affected (0.00 sec)Case 1Now, MySQL ... Read More

How does “void *” differ in C and C++?

George John

George John

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

444 Views

In this section we will see what are the differences between void pointer in C and void pointer in C++. They are both void pointers but in C a void pointer can be assigned to any pointer type, but in C++, we cannot do that. In C++ we have to ... Read More

Creation of .ASM file using a text editor

George John

George John

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

3K+ Views

The program written in assembly language is entered by us by the help of any editor, we prefer a screen editor because when we enter the program it is of no importance for the particular exact column label of instructions and the starting of the program. But the point to ... Read More

Basic or simple data transfer in 8085

George John

George John

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

237 Views

 The simplest data transfer scheme is the basic or simple data transfer. This method is beneficial to us when we have accurate knowledge of the Input-Output device timing characteristics. When we become familiar that the device is ready for transferring data, we execute the instructions IN and OUT, depending on ... Read More

How to get the difference between two columns in a new column in MySQL?

George John

George John

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

6K+ Views

Let us first create a table with columns for which we will calculate the difference in a new column −mysql> create table DemoTable (    Id int NOT NULL AUTO_INCREMENT PRIMARY KEY,    LowValue int,    HighValue int ); Query OK, 0 rows affected (0.62 sec)Insert some records in the ... Read More

The toString() method of CopyOnWriteArrayList in Java

George John

George John

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

80 Views

To get the string representation of the CopyOnWriteArrayList, use the toString() method in Java.The syntax is as followsString toString()To work with CopyOnWriteArrayList class, you need to import the following packageimport java.util.concurrent.CopyOnWriteArrayList;The following is an example to implement CopyOnWriteArrayList class toString() method in JavaExample Live Demoimport java.util.concurrent.CopyOnWriteArrayList; public class Demo { ... Read More

Advertisements