Quantum figuring contemplates hypothetical calculation frameworks (quantum PCs) that make coordinate utilization of quantum-mechanical marvels, for example, superposition to perform operations on data. Quantum PCs are unique in relation to binary digital PCs in light of transistors.While regular advanced registering requires that the information is encoded into twofold digits (bits), each of which is dependable in one of two distinct states (0 or 1), quantum calculation utilizes quantum bits, which can be in superpositions of states. A Quantum Turing Machine is a hypothetical model of such a PC and is otherwise called the general quantum PC.What are they?Starting at 2017, ... Read More
In this program we will see how to find the smallest number from a block of bytes using 8085.Problem StatementWrite 8085 Assembly language program to find the smallest number from a block of bytes.DiscussionIn this program the data are stored at location 8001H onwards. The 8000H is containing the size of the block. After executing this program, it will return the smallest number and store it at location 9000H.Logic is simple, we are taking the first number at register B to start the job. In each iteration we are getting the number from memory and storing it into register A. ... Read More
In this program we will see how to add two 16-bit numbers.Problem StatementWrite8085 Assembly language program to add two 16-bit number stored in memory location 8000H – 8001H and 8002H – 8003H.DiscussionIn this program we are pointing the operand addresses using HL and DE register pair. Then adding LSBytes by ADD operator, and after that adding MSBytes using ADC operator to consider the carry flag result. The 16-bit result will be stored at BC register, and by checking the carry bit after addition we can simply put 1 into memory.We are taking two numbersBCAD + FE2D = 1BADAInputAddressData......8000AD8001BC80022D8003FE......Flow DiagramProgramAddressHEX CodesLabelsMnemonicsCommentsF00021, ... Read More
To get ER model of database from server, you need to first launch MySQL Workbench. The snapshot is as follows −After that you need to select the “Database” menu −Database->Reverse EngineerAfter that a wizard will open as in the following screenshot. Add the password and press OK twice.After pressing the OK button, you will get the next wizard and you need to press next button. The following would be visible now −After that you need to select “Model” menu as I have marked in the above wizard.Model->Create Diagram from Catalog Objects After selecting the option, you will get the ER ... Read More
To format year in yy format is like displaying year as 01, 02, 03, 04, etc. For example, 18 for 2018.Use the yy format like this.SimpleDateFormat("yy");Let us see an example −// year in yy format SimpleDateFormat simpleformat = new SimpleDateFormat("yy"); String strYear = simpleformat.format(new Date()); System.out.println("Current Year = "+strYear);Above, we have used the SimpleDateFormat class, therefore the following package is imported −import java.text.SimpleDateFormat;The following is an example −Example Live Demoimport java.text.Format; import java.text.SimpleDateFormat; import java.util.Date; import java.util.Calendar; public class Demo { public static void main(String[] args) throws Exception { // displaying current ... Read More
In this program we will see how to add two 8-bit BCD numbers.Problem StatementWrite 8085 Assembly language program to add two 8-bit BCD number stored in memory location 8000H – 8001H.DiscussionThis task is too simple. Here we are taking the numbers from memory and after adding we need to put DAA instruction to adjust the accumulator content to decimal form. The DAA will check the AC and CY flags to adjust a number to its decimal form.InputAddressData......800099800125......Flow DiagramProgramAddressHEX CodesLabelsMnemonicsCommentsF00021, 00, 80LXI H, 8000HPoint to first operandF0037EMOV A, MLoad A with first operandF00423INX HPoint to next operandF00586ADD MAdd Acc and memory ... Read More
Before getting into grid Layout manager for recycler view example, we should know what is Recycler view in android. Recycler view is more advanced version of list view and it works based on View holder design pattern. Using recycler view we can show grids and list of items.This example demonstrate about how to integrate Recycler View with Grid layout manager by creating a beautiful student records app that displays student name with age.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 − ... Read More
This is a python program to print all the numbers which are divisible by 3 and 5 from a given interger N. There are numerous ways we can write this program except that we need to check if the number is fully divisble by both 3 and 5.Below is my code to write a python program to print all the numbers divisible by 3 and 5 −lower = int(input("Enter lower range limit:")) upper = int(input("Enter upper range limit:")) for i in range(lower, upper+1): if((i%3==0) & (i%5==0)): print(i)OutputEnter lower range limit:0 Enter upper range limit:99 0 15 ... Read More
To drop a database with the character ‘?’ in its name, you need to use backtick symbol around the database name. The syntax is as follows −DROP DATABASE `yourDatabaseName`;To understand the above syntax, let us create a database. The query to create a database is as follows −mysql> create database `test?data`; Query OK, 1 row affected (0.14 sec)So, I have a database with? character. The query to show all databases is as follows −mysql> show databases;The following is the output −+-----------------------+ | Database | +-----------------------+ | business | ... Read More
Use the System.getProperty() method in Java to get the Java Specification Version.It’s syntax is −String getProperty(String key)Above, the key is the name of the system property. Since, we want the Java Specification Version name, therefore we will add the key as −java.specification.versionThe following is an example −Example Live Demopublic class Demo { public static void main(String[] args) { System.out.print("Java Specification Version: "); System.out.println(System.getProperty("java.specification.version")); } }OutputJava Specification Version: 1.8