elp so onnum
Operations
In mathematics and computer science, an operation is an event that is carried out to satisfy a given task. Basic operations of a computer system are input, processing, output, storage, and control.
Basic Operators
An operator is a symbol that indicates an operation to be performed. We are familiar with operators in mathematics; operators used in computer programming are—in many ways—similar to mathematical operators.
Division Operator
We all learnt about division—and the division operator—in school. You probably know of both these symbols as representing division:
Modulus Operator
Modulus can be represented either as (mod or modulo) in computing operation. Modulus comes under arithmetic operations. Any number or variable which produces absolute value is modulus functionality. Magnitude of any function is totally changed by modulo operator as it changes even negative value to positive.
Operators
In the realm of programming, operators refer to the symbols that perform some function. They are tasked with instructing the compiler on the type of action that needs to be performed on the values passed as operands. Operators can be used in mathematical formulas and equations. In programming languages like Python, C, and Java, a variety of operators are defined.
Help so onnum
![====Complete
this method===
Java method signature:
Node addNumbers (Node head, int [] A) {
// To Do
}
Python method signature:
def addNumbers (head, A):
#To Do
Given a random Linked List: 2 >> -4 >> 10
Given array:
0
33
Answer: 33>>2>>-4>>10
1
13
2
16
3
1
4
8
5
9](/v2/_next/image?url=https%3A%2F%2Fcontent.bartleby.com%2Fqna-images%2Fquestion%2F84d305fc-e861-4250-8822-5e6a32ff70d4%2F67855aaa-c8d8-4050-ba80-bda1485bcd89%2Fleinjfn_processed.png&w=3840&q=75)
![Read the tasks very carefully and draw the scenario before you go for code. You have to complete
the method addNumbers(head, A).
You are given a singly linked list (head) and an array (A) containing integers. Write a
JAVA/Python method where you have to create Nodes with the numbers from the array, which
are divisible by 3 and add them in the list in the positions defined by their indices. Be careful about
wrong indices. You might have a linked list of size 4 and you might find your desired number in
the array at index 10. Do not consider wrong indices. Look at the following diagram for clear
understanding.
Assume countNode() method is given. You are not allowed to use any other built in methods.
====Complete this method===
Java method signature:
Node addNumbers (Node head, int [] A) {
// To Do
}
Python method signature:
def addNumbers (head, A):
# To Do](/v2/_next/image?url=https%3A%2F%2Fcontent.bartleby.com%2Fqna-images%2Fquestion%2F84d305fc-e861-4250-8822-5e6a32ff70d4%2F67855aaa-c8d8-4050-ba80-bda1485bcd89%2Fv4yq7n3_processed.png&w=3840&q=75)

Step by step
Solved in 3 steps with 4 images









