>> a=[1;4;7]l; b=[2;-1;5]; >> c=dot (a,b) C = 33 >> d=cross (a, b) d = 27 6. -9 > x=a;y=Db'3; >> z=dot (x,y) Z= 33 >> w=cross (x, y) W = 27 -9
Q: program that takes in a text with dimacs format and checks whether the clause is satisfiable, if so,...
A: // Java implementation to find if the given // expression is satisfiable using the // Kosaraju's Alg...
Q: Storyboard dialogue Errand Assistance Service Application
A: Let's see the solution in the next steps
Q: Calculate the results (both binary and hexadecimal values) with calculation step and show the status...
A:
Q: Develop a java code to save the following string ("Lab", "Assessment", "total" "Marks", "is 5"} in S...
A: - We have to complete the stack program in java.
Q: What is gray leval of digital image ? If we use 8 bits for representing pixels, how many gray level ...
A: Grey level of digital image: The grey level or grey value indicates that the brightness of a pixel....
Q: Create an algorithm for determining the processor busy-period.
A: CPU Scheduling is the process of determining which process will have exclusive use of the CPU while ...
Q: main.e Tests Executions 2. Magic's Secrets Revealed 1 by CodeChum Admin CI Run Tests For centuries, ...
A: Ans: Code: #include<stdio.h>#include<conio.h> int main() { int size; printf("Enter t...
Q: Given the ip address 172.168.5.0/18, divide the network to create 8 subnetworks
A: Given IP address is, 172.168.5.0/18 18 bits are network id and 32-18= 14 bits are host id bits. Numb...
Q: Exercise: return object as parameters Complete the following program by completing the method named ...
A: Find the required code given as below and output:
Q: If you wanted to know the position of the letter v (i.e. return 2) in the String str containing the ...
A: A String is a pre defined class in Java which has various methods in it to perform the operations on...
Q: Why is it so important for those who work in technology to study and grasp the foundations of electr...
A: Introduction: Information technology enables the growth and extension of commercial and business sec...
Q: ab Activ a) Write a prolog program fo find the addition and multiplication of two numbers.
A: Prolog programming: An prolog programming language associated with AI(Artificial Intelligence). It ...
Q: 1) Construct K-D tree for the following data (3,6), (17,15), (13,15), (6,12), (9,1), (2,7), (10,19).
A: A K-D Tree(also called as K-Dimensional Tree) is a binary search tree where data in each node is a K...
Q: Recognize the type of information system that clerical staff in a company are most likely to use and...
A: Find the answer given as below :
Q: 1. Big-O has the highest growth rate. а. О(2") b. O(n) c. O(n*) d. O(n°)
A: A theoretical measure of the execution of an algorithm, usually the time needed, given the problem s...
Q: Write a program that has an array of at least 20 integers. It should call a function that uses the l...
A: The Answer is
Q: Explain the fundamental procedures involved in MapReduce processing.
A: Introduction: MapReduce: Hadoop's processing layer is MapReduce. It's a free and open-source applica...
Q: Instructions Create a program that contains a function append_combine(x, a) where x is a list of int...
A: Since no programming language is mentioned, I am using python. Algorithm: Start Implement a method ...
Q: Write ONLY Header (No body{}) of function for each question. You can use any valid variable name for...
A: A constructor is a special function that has name same as that of class So the function name here wi...
Q: Please help to draw a diagram that details the components and types of links between two buildings t...
A: Here's how to solve the aforesaid issue: - Talk about the infrastructure that will be required. A WA...
Q: Given a memory address 0x0000FF13 (decimal = 65299). Is it a valid address of an array of words? Why...
A: Let's see the solution in the next steps
Q: what is octal cable computer networking? writes its Uses? advantages and Disadvantages?
A: Lets see the solution in the next steps
Q: ny of the 3 number from the user, generate a random number between 1 to 3 itself and then apply the ...
A: After going throught the program requirements, the project is implemented in Java using sockets File...
Q: Describe the components of a disaster recovery plan. What is the difference between backup plans for...
A: Introduction: Each information system is designed with backup devices to ensure that data and inform...
Q: Do you know how to tell the difference between main and secondary memory?'
A: Given:
Q: ii) In JAVA language input the elements of an integer array A of size 10 and find the count of all h...
A: In JAVA language input the elements of an integer array A of size 10 and find the count of all hills...
Q: What is a data cube? Define three data dimensions of a data cube that might be used to analyze sales...
A: A Data solid shape as its name recommends is an augmentation of a 2-Dimensional information 3D squar...
Q: different teams. Each developer has her/his own laptop which runs Windows 10. The development enviro...
A: Case StudyPQS is an online retail shop in Sydney, Australia. Its website, where the users can explor...
Q: Create two enumerations that hold colors and car model types. You will use them as field types in a ...
A: Enumerations are created using the keyword "enum" . "enum" is a special type of class which represen...
Q: nsider: lic static void printAll(int[] a) { N = a.length;
A:
Q: The three levels inheritance hierarchy is shown in the UML below. A) A set of pre-conditions...
A: : Solution :: A) Super class has a wide range available and subclasses must be within the same wide ...
Q: 3. 'Use Comparison Theorem to determine if the following converge or diverge. a) dx 2 in(x) Vx-4 sin...
A: The integrals module in SymPy implements methods to calculate definite and indefinite integrals of e...
Q: Write a code to get the data present at the pins of PORT C and sends it to PORT B indefinitely. Use ...
A: here we have given certain code to get the data present at the pins of PORT C and sends it toPORT B ...
Q: 8.5 Assume we are searching a tree with branching factor b. However, we do not know that we are real...
A: Here,Assume we are searching a tree with branching factor b.However,we do not know that we are reall...
Q: What is the definition of a disjoint subtype? Please provide an example.
A: Introduction: If an instance of a type corresponds to only one example of a subtype, it is said to h...
Q: What is open source in computer science?
A: This question comes from Internet Technologies which is a paper of computer science. Let's discuss i...
Q: Create Ansoff matrix For Software applications Company
A: I have answered this question in step 2.
Q: Using the online javadoc for the Java 8 (or later) API fill in the words int he following sentence. ...
A: Java is a renowned language which is widely used since many years. It helps in producing multiple so...
Q: Q20-Following Grammar is give (I am using or instead of usual | to avoid confusion) a) Find the Firs...
A: Answers: We have to provide the detailed solution in the below Picture:
Q: --> x - linspace (-20, 20,1000); --> yl - x. *sin (x); --> y2 - -x3; > plot (x, y1, 'b',x, y2, 'r');...
A: # importing libraries import matplotlib.pyplot as p import numpy # defining x and y axis x = numpy.l...
Q: Create a storyboard and description about errands assistance service application (ease App
A: Let's see the solution in the next steps
Q: In the case of Public Key Authority It is necessary to make a request for B's public key, and the Pu...
A: Introduction: In a key exchange, one party generates the secret key and encrypts it using the recipi...
Q: Find the angular velocity from velocity and radius in python
A: The inputs will be the velocity, radius and the output will be angular velocity Angular velocity is ...
Q: I want codes java to customer and citizen @Citizen model nationalNo: int - bDate: Date nationality:...
A: In this program, there are two classes Citizen and Consumer. In Citizen class we have 3 properties n...
Q: ii) In JAVA language input the elements of an integer array A of size 10 and find the count of all h...
A: Given: An array A of size 10 is given and we have input its elements from the user. All elements of ...
Q: What is shoulder surfing? A. B. C. D. Question options: a. Leaving a physical med...
A: In this we have to understand what is shoulder surfing ? We will understand it by given options and...
Q: . Simplify the following Boolean functions, using four-variable Kmaps: (a) F (w, x, y, z) = Σ(1, 4, ...
A: for all three parts , I have provided HAND-WRITTEN solution images---------
Q: Matlab Plot the signal in matlab software Need code and output
A: Write a MATLAB program to plot the given signal and attach the code and output.
Q: Write a loop to display the powers of 2 exactly as shown below 1 2 4 8. 16 32 64 128
A: The Answer is given below step.
Q: What is open source in computer science?
A: 1) The term open source refers to something people can modify and share because its design is public...
Step by step
Solved in 2 steps
- Computer Science IN C++ Write a program that implements the game tic-tac-toe: Tic-Tac-Toe is a game played on a three-by-three board. Two players, X and O, alternate in placing their respective marks in the cells of this board, starting with player X. If either player succeeds in getting three of his or her marks in a row, column, or diagonal, then that player wins. In this homework, you should use the OOP concepts to implement the tic-tac-toe game.Knight's Tour: The Knight's Tour is a mathematical problem involving a knight on a chessboard. The knight is placed on the empty board and, moving according to the rules of chess, must visit each square exactly once. There are several billion solutions to the problem, of which about 122,000,000 have the knight finishing on the same square on which it begins. When this occurs the tour is said to be closed. Your assignment is to write a program that gives a solution to the Knight's Tour problem recursively. You must hand in a solution in C++ AND Java. The name of the C++ file should be "main.cc" and the name of the Java file should be "Main.java". Write C++ only with a file name of main.cc Please run in IDE and check to ensure that there are no errors occuring Output should look similar to: 1 34 3 18 49 32 13 16 4 19 56 33 14 17 50 31 57 2 35 48 55 52 15 12 20 5 60 53 36 47 30 51 41 58 37 46 61 54 11 26 6 21 42 59 38 27 64 29 43 40 23 8 45 62 25 10 22 7 44 39 24 9 28 63Transcribed Image Text JAVA Programming Problem: In the game of "Assassin's Creed", you control a ship with a cannon which is attacking a large enemy Assassin's Creed, armed with many guns. Your goal is to destroy as many of the guns as possible. The battle field is a 2D Cartesian grid, where your cannon is located at the origin. The enemy Assassin's Creed is a horizontal line segment located from the coordinates (X1, Y) to (X2, Y). There are exactly (X2 - X1 + 1) guns on the ship, located at the integer points (X1, Y), (X1+1, Y), ..., (X2, Y). However, the problem is, you cannot always fire at a gun. There are supernatural rocks located at all points of the battlefield whose X and Y coordinates are both integers. In order to fire successfully at an enemy's gun, the line connecting your cannon and that gun must not go through any rocks. Develop a JAVA code to output the number of the enemy battleship's guns that your cannon can destroy. Test Case Result 1 2 2 -2
- Q1.com Code. Given a 2d grid map of '1's (land) and '0's (water),count the number of islands.An island is surrounded by water and is formed byconnecting adjacent lands horizontally or vertically.You may assume all four edges of the grid are all surrounded by water. Example 1: 11110110101100000000Answer: 1 Example 2: 11000110000010000011Answer: 3""" def num_islands(grid): count = 0 for i in range(len(grid)): for j, col in enumerate(grid[i]): if col == 1: dfs(grid, i, j) count += 1 Please code it. .C Programming Language (Code With C Programming Language) Problem Title : Visible Trees There is a legend about a magical park with N × N trees. The trees are positioned in a square grid with N rows (numbered from 1 to N from north to south) and N columns (numbered from 1 to N from west to east). The height (in metres) of each tree is an integer between 1 and N × N, inclusive. Magically, the height of all trees is unique. Bunga is standing on the northmost point of the park and wants to count the number of visible trees for each Column. Similarly, Lestari is standing on the westmost point of the park and wants to count the number of visible trees for each Row. A tree X is visible if all other trees in front of the tree X are shorter than the tree X. For example, let N = 3 and the height (in metres) of the trees are as follows6 1 87 5 32 9 4 On the first column, Bunga can see two trees, as the tree on the third row is obstructed by the other trees. On the second column, Bunga can see…In C programming language write Task 2: Hangman gameWrite a terminal based on the game of Hangman. In a hangman game, the player is given a wordthat they need to guess, with each letter of the word represented by an underscore/blank. Theplayer tries to guess a letter of the word by entering it into the terminal. If the letter is correct, theblank corresponding to that letter is filled in. If the letter is incorrect, a part of a stick figure isdrawn. The player has a limited number of incorrect guesses before the stick figure is fully drawnand the game is lost. The player wins the game if they guess all the letters of the word before thestick figure is fully drawn.The program should have an array of possible words to choose from. A different word should berandomly chosen from the array every time we run the program.Others: Do not use GOTO statements
- C++ Language Write a program that prints a custom conversion table from Celsius temperatures to Fahrenheit and Newton (Links to an external site.) temperatures. The formula for the conversion from Celsius to Fahrenheit is : F=9/5*C+32 F is the Fahrenheit temperature, and C is the Celsius temperature. The formula for the conversion from Celsius to Newton is C = 100/33*N N is the Newton Temperature and C is the Celsius temperature Your program should prompt the user for a lower value and upper value for a range of temperatures in Celsius. It should then prompt the user for the amount they want to increment by. Then use a loop to output to a file named conversion_table.txt a table of the Celsius temperatures and their Fahrenheit and Newton equivalents within the range of values using the increment given by the user. Make sure to format your output to 2 decimal places. INPUT VALIDATION: Ensure the second number is greater than the first number, and make sure the increment is greater…coding in C++ Tic Tac Toe game that will match a player against the computer. Do's: Use a typical 3 x 3 board. The horizontal axis should be labeled A, B, C. The vertical axis should be labeled 1, 2, 3. The horizontal axis (ROWS) should be labeled A, B, C. The vertical axis (COLUMNS)should be labeled 1, 2, 3. Use User-Defined Functions. Use Branching. Use Loops. Use String functions. Randomly determine who will move first, the human or computer. Assign O to the computer and X to the Human player. Ask the user to select their move using the horizontal and vertical position. For example: A1 for the upper left square, or B2 for the center square. After each move, redraw the board with the X's and O's in the right positions. After each game, ask the user if they want to play again. If they do, start the game again. Do not's: Don't use User Classes or Objects Don't use imagesQ // Write a program in C++ language that enters a number of integer numbers into a singular matrix whose size is renewed after asking the user about the number of numbers he wants to enter, then he collects these numbers and prints the result on the screen
- Question: Write a program to Simulate a game of tic tac toe. A game of tic tac toe has two players. A Player class is required to store /represent information about each player. The UML diagram is given below. Player -name: string -symbol :char Player (name:string,symbol:char) getName():string getSymbol():char getInfo():string The tic tac toe board will be represented by a two dimensional array of size 3 by 3 characters. At the start of the game each cell is empty (must be set to the underscore character ‘_’). Program flow: Your program must ask for each player’s name and their special symbol or character (usually an ‘X’ or ‘O’). Display each player’s name and symbol. The program must then display the board (the 2 dimensional array). The player whose turn it is has their name displayed and is asked for a row and column number to place their symbol. They can enter -1 -1 as the row and column number to quit. Repeat 2 and 3 until one player enters -1 -1. Your…DescriptionA researcher is analyzing DNA. A DNA can be represented as a string composed of the characters A, G, C, or T.One day, researchers found a strange DNA, which is Smooth Repeated DNA. The DNA is represented by a string that has infinite length. The string has a repeating pattern, i.e. the DNA string 0 is repeated an infinite number of times. For example, if0 = "????", then = "???????????? . . . ".According to researchers, a DNA is said to be special if it contains substrings . Determine whetheris a substring of . Squad FormatA line containing the two strings 0 and . Output FormatA line that determines whether it is a substring of . Issue “YES” ifis a substring of . Output “NO” otherwise. Example Input and Output Input Example Example Output AGCT GC YES AGCT TA YES AGCT GT No AGCT TAGCTAGCT YES AGGACCTA CTAA YES Explanation ExampleIn the first to fourth test case examples, is worth "???????????? . . . ". The part in bold is one of the…javascript only: Write a function `popularLetters(string)` that takes a string as an argument and returns an array of all of the characters that appear five or more times in the string. Examples: console.log(popularLetters('apple')); // [] console.log(popularLetters('bananas in pajamas')); // [ 'a' ] console.log(popularLetters('Yes, we have no bananas, we have no bananas today!')); // [ 'e', ' ', 'a', 'n' ]