Samual Sam has Published 2310 Articles

Check two ArrayList for equality in Java

Samual Sam

Samual Sam

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

839 Views

Two ArrayList can be compared to check if they are equal or not using the method java.util.ArrayList.equals(). This method has a single parameter i.e. an ArrayList that is compared with the current object. It returns true if the two ArrayList are equal and false otherwise.A program that demonstrates this is ... Read More

header() function in PHP

Samual Sam

Samual Sam

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

508 Views

The header() function sends a raw HTTP header to a client.Syntaxheader(string, replace, resp_code)Parametersstring − The header string to send.replace − Indicates whether the header should replace previous or add a second header.resp_code − It forces the HTTP response code to the specified valueReturnThe header() function returns nothing.ExampleThe following is an ... Read More

ftp_cdup() function in PHP

Samual Sam

Samual Sam

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

159 Views

The ftp_cdup() function changes the current directory to the parent directory.Syntaxftp_cdup(con);Parameterscon − The FTP connectionReturnThe ftp_cdup() function returns TRUE on success or FALSE on failure.ExampleThe following is an example wherein we are updating the current directory to parent directory −

Python Implementation of automatic Tic Tac Toe game using random number

Samual Sam

Samual Sam

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

1K+ Views

This is very funny game. In this game no player is needed, it is an automatic game. Here we are using two Python modules numpy and random. In this game the mark on the board is put automatically instead of asking the user to put a mark on the board, ... Read More

Draw an ellipse in C#

Samual Sam

Samual Sam

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

3K+ Views

To draw an ellipse, use the drawEllipse() method in C# that belong to the Graphics object. It has a pen object as well as a rectangle object. You need windows form to draw shapes in C#. Set graphics object. Graphics g = this.CreateGraphics(); Now, the pen ... Read More

char vs string keywords in C#

Samual Sam

Samual Sam

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

1K+ Views

string keyword Use the string keyword to declare a string variable. The string keyword is an alias for the System.String class. For example. string name; name = "Tom Hanks"; Another example. string [] array={ "Hello", "From", "Tutorials", "Point" }; char keyword The char keyword is used ... Read More

Instruction type INR R in 8085 Microprocessor

Samual Sam

Samual Sam

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

10K+ Views

In 8085 Instruction set, INR is a mnemonic that stands for ‘INcRement’ and ‘R’ stands for any of the following registers or memory location M pointed by HL pair. R = A, B, C, D, E, H, L, or M This instruction is used to add 1 with ... Read More

Fetching top news using news API in Python

Samual Sam

Samual Sam

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

703 Views

News API is very famous API for searching and fetching news articles from any web site, using this API anyone can fetch top 10 heading line of news from any web site. But using this API, one thing is required which is the API key. Example Code import requests ... Read More

Instruction type ACI d8 in 8085 Microprocessor

Samual Sam

Samual Sam

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

2K+ Views

In 8085 Instruction set, ACI is a mnemonic which stands for 'Add with Carry Immediate to Accumulator' and here “d8” stands for any 8-bit or 1-Bytedata. This instruction is actually meant for adding one 8-bit immediate data or operand to the Accumulator along with the carry value. The result of ... Read More

Python program multiplication of two matrix.

Samual Sam

Samual Sam

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

20K+ Views

Given two user input matrix. Our task is to display the addition of two matrix. In these problem we use nested List comprehensive. Algorithm Step1: input two matrix. Step 2: nested for loops to iterate through each row and each column. Step 3: take one resultant matrix which is ... Read More

Advertisements