Arjun Thakur has Published 1109 Articles

8085 Program to convert a 16-bit binary number to BCD

Arjun Thakur

Arjun Thakur

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

1K+ Views

Now let us see a program of Intel 8085 Microprocessor. In this program we will see how to convert 16-bit binary data to BCD data.Problem Statement:Write 8085 Assembly language program to convert 16-bit binary data to BCD data. The binary data is stored at location 8000H and 8001H.Discussion:This problem is ... Read More

How can I use MongoDB to find all documents which have a field, regardless of the value of that field?

Arjun Thakur

Arjun Thakur

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

70 Views

To use MongoDB to find all documents which have a field, regardless of the value of that field, use the $exists operator. Following is the syntaxdb.yourCollectionName.find({yourFieldName:{$exists:true}});Let us create a collection with documents>db.findAllDocumentWhichHaveFieldDemo.insertOne({"StudentName":"John", "StudentAge":null}); {    "acknowledged" : true,    "insertedId" : ObjectId("5c9d1d60a629b87623db1b22") } >db.findAllDocumentWhichHaveFieldDemo.insertOne({"StudentName":"Larry", "StudentAge":null}); {    "acknowledged" : true, ... Read More

8086 program to add two 8 bit BCD numbers

Arjun Thakur

Arjun Thakur

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

4K+ Views

In this program we will see how to add two 8-bit BCD numbers.Problem StatementWrite 8086 Assembly language program to add two 8-bit BCD number stored in memory address offset 600.DiscussionThis task is too simple. Here we are taking the numbers from memory and after adding we need to put DAA ... Read More

C++ Program to Generate a Random Directed Acyclic Graph DAC for a Given Number of Edges

Arjun Thakur

Arjun Thakur

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

436 Views

In this program we generate a random directed acyclic graph for the given edges ‘e’. The time complexity of this program is O(e*v*e).AlgorithmBegin    function GenerateRandomGraphs(), has ‘e’ as the number edges in the argument list.    generate a connection between two random numbers, for sample a small case, limit ... Read More

How to find edit text values start from Number is Even or Odd?

Arjun Thakur

Arjun Thakur

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

1K+ Views

This example demonstrate about How to find edit text values start from Number is Even or Odd.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. ... Read More

The clear() method of AbstractSequentialList in Java

Arjun Thakur

Arjun Thakur

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

59 Views

The clear() method is inherited from the AbstractList class. It allows you to remove all the elements from the list.The syntax is as followspublic void clear()To work with the AbstractSequentialList class in Java, you need to import the following packageimport java.util.AbstractSequentialList;The following is an example to implement AbstractSequentialList clear() method ... Read More

How can you read a request header information in JSP?

Arjun Thakur

Arjun Thakur

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

377 Views

Following is the example which uses getHeaderNames() method of HttpServletRequest to read the HTTP header information. This method returns an Enumeration that contains the header information associated with the current HTTP request.Once we have an Enumeration, we can loop down the Enumeration in the standard manner. We will use the ... Read More

How to improve querying field in MongoDB?

Arjun Thakur

Arjun Thakur

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

82 Views

To improve querying field in MongoDB, you need to use index. Let us create a collection with documents> db.improveQueryDemo.insertOne( ... { ...    "PlayerDetails":[ ...       {"PlayerName": "John", "PlayerGameScore": 5690}, ...       {"PlayerName": "Carol", "PlayerGameScore": 2690}, ...    ] ... } ... ); {    "acknowledged" ... Read More

C++ Program to Find Transpose of a Graph Matrix

Arjun Thakur

Arjun Thakur

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

249 Views

In this program we take a matrix and prints the transpose of the matrix. In a transpose matrix, rows become columns and vice versa.AlgorithmBegin Take number of rows and columns of the matrix. Take The elements of the matrix and stored in the matrix ... Read More

LongStream average() method in Java

Arjun Thakur

Arjun Thakur

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

332 Views

The average() method of the LongStream class in Java returns an OptionalDouble describing the arithmetic mean of elements of this stream, or an empty optional if this stream is empty.The syntax is as follows.OptionalDouble average()Here, OptionalDouble is a container object which may or may not contain a double value.To use ... Read More

Advertisements