Answer:
"if" is the right response.
Explanation:
Forward chaining is being utilized just to split the logical sequential order down as well as operate throughout every component once the preceding one is accomplished, from start to finish.Its whole algorithm begins with proven information that activates all the rules, which are fulfilled as well as makes established realities even more complete.discribe two ways you can zoom in and out from an image
Write a C program to input a character, then check if the input
character is digit, letter, or other character.
Answer:
// CPP program to find type of input character
#include <iostream>
using namespace std;
void charCheck(char input_char)
{
// CHECKING FOR ALPHABET
if ((input_char >= 65 && input_char <= 90)
|| (input_char >= 97 && input_char <= 122))
cout << " Alphabet ";
// CHECKING FOR DIGITS
else if (input_char >= 48 && input_char <= 57)
cout << " Digit ";
// OTHERWISE SPECIAL CHARACTER
else
cout << " Special Character ";
}
// Driver Code
int main()
{
char input_char = '$';
charCheck(input_char);
return 0;
}
Explanation:
// CPP program to find type of input character
#include <iostream>
using namespace std;
void charCheck(char input_char)
{
// CHECKING FOR ALPHABET
if ((input_char >= 65 && input_char <= 90)
|| (input_char >= 97 && input_char <= 122))
cout << " Alphabet ";
// CHECKING FOR DIGITS
else if (input_char >= 48 && input_char <= 57)
cout << " Digit ";
// OTHERWISE SPECIAL CHARACTER
else
cout << " Special Character ";
}
// Driver Code
int main()
{
char input_char = '$';
charCheck(input_char);
return 0;
}
If you lose yellow from your printer, what would happen to the picture?
Answer:
The picture would be green.
Write a Python program stored in a file q1.py to play Rock-Paper-Scissors. In this game, two players count aloud to three, swinging their hand in a fist each time. When both players say three, the players throw one of three gestures: Rock beats scissors Scissors beats paper Paper beats rock Your task is to have a user play Rock-Paper-Scissors against a computer opponent that randomly picks a throw. You will ask the user how many points are required to win the game. The Rock-Paper-Scissors game is composed of rounds, where the winner of a round scores a single point. The user and computer play the game until the desired number of points to win the game is reached. Note: Within a round, if there is a tie (i.e., the user picks the same throw as the computer), prompt the user to throw again and generate a new throw for the computer. The computer and user continue throwing until there is a winner for the round.
Answer:
The program is as follows:
import random
print("Rock\nPaper\nScissors")
points = int(input("Points to win the game: "))
player_point = 0; computer_point = 0
while player_point != points and computer_point != points:
computer = random.choice(['Rock', 'Paper', 'Scissors'])
player = input('Choose: ')
if player == computer:
print('A tie - Both players chose '+player)
elif (player.lower() == "Rock".lower() and computer.lower() == "Scissors".lower()) or (player.lower() == "Paper".lower() and computer.lower() == "Rock".lower()) or (player == "Scissors" and computer.lower() == "Paper".lower()):
print('Player won! '+player +' beats '+computer)
player_point+=1
else:
print('Computer won! '+computer+' beats '+player)
computer_point+=1
print("Player:",player_point)
print("Computer:",computer_point)
Explanation:
This imports the random module
import random
This prints the three possible selections
print("Rock\nPaper\nScissors")
This gets input for the number of points to win
points = int(input("Points to win the game: "))
This initializes the player and the computer point to 0
player_point = 0; computer_point = 0
The following loop is repeated until the player or the computer gets to the winning point
while player_point != points and computer_point != points:
The computer makes selection
computer = random.choice(['Rock', 'Paper', 'Scissors'])
The player enters his selection
player = input('Choose: ')
If both selections are the same, then there is a tie
if player == computer:
print('A tie - Both players chose '+player)
If otherwise, further comparison is made
elif (player.lower() == "Rock".lower() and computer.lower() == "Scissors".lower()) or (player.lower() == "Paper".lower() and computer.lower() == "Rock".lower()) or (player == "Scissors" and computer.lower() == "Paper".lower()):
If the player wins, then the player's point is incremented by 1
print('Player won! '+player +' beats '+computer)
player_point+=1
If the computer wins, then the computer's point is incremented by 1
else:
print('Computer won! '+computer+' beats '+player)
computer_point+=1
At the end of the game, the player's and the computer's points are printed
print("Player:",player_point)
print("Computer:",computer_point)
Write a program that uses the function strcmp() to compare two strings input by the user. The program should state whether the first string is less than, equal to, or greater than the second string7. Write a program that uses the function strcmp() to compare two strings input by the user. The program should state whether the first string is less than, equal to, or greater than the second string
user_str1 = str ( input ("Please enter a phrase: "))
user_str2 = str ( input("Please enter a second phrase: "))
def strcmp (word):
user_in1 = int (len(user_str1))
user_in2 = int (len(user_str2))
if user_in1 > user_in2:
return "Your first phrase is longer"
elif user_in1 < user_in2:
return "Your second phrase is longer"
else:
return "Your phrases are of equal length"
Select the pseudo-code that corresponds to the following assembly code. Assume that the variables a, b, c, and d are initialized elsewhere in the program. You may want to review the usage of EAX, AH, and AL (IA32 registers). Also recall that the inequality a > b is equivalent to b < a. i.e. If A is greater than B, that's equivalent to saying that B is less than A.
.data
; General purpose variables
a DWORD ?
b DWORD ?
c BYTE ?
d BYTE ?
upperLevel DWORD 18
lowerLevel DWORD 3
; Strings
yes BYTE "Yes",0
no BYTE "No",0
maybe BYTE "Maybe",0
code
main PROC
mov eax, 1
cmp AH, c
jg option1
jmp option3
option1:
mov edx, OFFSET yes
call WriteString
jmp endOfProgram
option2:
mov edx, OFFSET no
call WriteString
jmp endOfProgram
option3:
mov edx, OFFSET maybe
call WriteString
endOfProgram:
exit
main ENDP
END main
a) if (c > 0)
print (yes);
else
print (maybe);
b) if (c < 0)
print (yes);
else
print (maybe);
c) if (c < 1)
print (yes);
else
print (maybe);
d) if (c > 1)
print (yes);
else
print (maybe);
Answer:
ae
Explanation:
The pseudo-code that corresponds to the given assembly code is:
b) if (c < 0)
print (yes);
else
print (maybe);
What is the pseudo-codeIn assembly code, the command cmp AH, c checks if the high byte of the EAX register (AH) has the same value as the variable c. Then, if the value in AH is more than the value in c, the instruction jg option1 will move to option1.
Therefore, In the pseudo-code, one can check if c is smaller than 0. If it happens, we say "yes". If not, we say "maybe"
Read more about pseudo-code here:
https://brainly.com/question/24953880
#SPJ2
I need it in code please (python)
Answer:
def main():
n = int(input("Enter a number to find its sum! "))
sum = int((n*(n+1)) / 2)
print(str(sum))
main()
Explanation:
Here is some code I quickly came up with, you can rehash it for your liking.
I basically took this formula and translated it into python code on line 3. Make sure you use paratheses correctly when translating forumlas or any equation, Order of Operations is everything.
Lmk if this helped!
Transitive spread refers to the effect of the original things transmitted to the associate things through the material, energy or information.
a. True
b. False
Create a parent class called Shape with width and height parameters of type double and a function that returns the area of the shape, which simply returns 0. Then define two subclasses, Rectangle, and Triangle, that override the area function to return the actual area (width*height for Rectangle and 1/2*width*height for Triangle).
The code must be in java
Answer:
umm im not sure tbh
Explanation:
Ellen is working on a form in Access and clicks on the Design tab in the Form Design Tools section. Ellen then clicks on the Controls button and clicks the Label icon. What is Ellen most likely doing to the form?
A.adding a title
B.adding an existing field
C.changing the anchoring setting
D.changing the font of a label
Answer:
D. changing the font of a label
Write steps to Delete data from ‘Datagridview’
Explanation:
private void btnDelete_Click(object sender, EventArgs e)
{
if (this.dataGridView1.SelectedRows.Count > 0)
{
dataGridView1.Rows.RemoveAt(this.dataGridView1.SelectedRows[0].Index);
}
}
A desktop computer is a type of mobile device.
a. true
b. false
A desktop computer is a type of mobile device: B. False.
What is a desktop computer?A desktop computer simply refers to an electronic device that is designed and developed to receive data in its raw form as an input and processes these data into an output that's usable by an end user.
Generally, desktop computers are fitted with a power supply unit (PSU) and designed to be used with an external display screen (monitor) unlike mobile device.
In conclusion, a desktop computer is not a type of mobile device.
Learn more about desktop computer here: brainly.com/question/959479
#SPJ9
which computer are used by mobile employees as Meter readers.
Explanation:
handheld computers
Some handheld computers have miniature or specialized keyboards. Many handheld computers are industry-specific and serve the needs of mobile employees, such as meter readers and parcel delivery people, whose jobs require them to move from place to place.
For the following scenario, indicate whether the action is a good practice or bad practice to safeguard your personally identifiable information.
Marina's personal computer requires a password to get access.
Answer:
This is most definitely a good practice to safeguard personal information. This way, people wouldn't be able to access her computer easily, since it requires a code that only she would know. of course, there is the possibility that someone can just guess or hack into her computer, but that's why computers usually have you create a unique code that consists of uppercases, lowercases, numbers, special characters, etc which would be difficult to guess. it's a good protection for anyone who wants to safely keep their personal information from everyone else.
10 features of the ribbon in microsoft word
Answer:yes
Explanation:
Yup
Which of the following definitions best describes the principle of separation of duties?
Answer:
A security stance that allows all communications except those prohibited by specific deny exceptions
A plan to restore the mission-critical functions of the organization once they have been interrupted by an adverse event
A security guideline, procedure, or recommendation manua
lAn administrative rule whereby no single individual possesses sufficient rights to perform certain actions
1. Write an application that throws and catches an ArithmeticException when you attempt to take the square root of a negative value. Prompt the user for an input value and try the Math.sqrt() method on it. The application either displays the square root or catches the thrown Exception and displays an appropriate message. Save the file as SqrtException.java.
2. Create a ProductException class whose constructor receives a String that
consists of a product number and price. Save the file as ProductException.java.
Create a Product class with two fields, productNum and price. The Product
constructor requires values for both fields. Upon construction, throw a
ProductException if the product number does not consist of three digits, if the
price is less than $0.01, or if the price is over $1,000. Save the class as Product.java.
Write an application that establishes at least four Product objects with valid and invalid values. Display an appropriate message when a Product object is created
successfully and when one is not. Save the file as ThrowProductException.java.
Answer:
Hence the answer is given as follows,
various gabs in the digital divide
Answer:
factors such as low literacy and income level Geographical restriction lack of motivation motivation of the technology lack of motivation to use technology and digital illiteracy and contribute to the digital device
Help Pls
I need about 5 advantages of E-learning
Answer:
Explanation:
E-learning saves time and money. With online learning, your learners can access content anywhere and anytime. ...
E-learning leads to better retention. ...
E-learning is consistent. ...
E-learning is scalable. ...
E-learning offers personalization.
Answer:
E- learning saves time and money
E-learning makes work easier and faster
E- learning is convenient
E- learning is consistent
E- learning is scalable
Explanation:
when you learn using the internet, you save a lot of time by just typing and not searching through books
Using simplified language and numbers, using large font type with more spacing between questions, and having students record answers directly on their tests are all examples of _____. Group of answer choices universal design analytic scoring cheating deterrents guidelines to assemble tests
Answer:
universal design
Explanation:
Using simplified language and numbers, using large font type with more spacing between questions, and having students record answers directly on their tests are all examples of universal design.
Universal Design can be regarded as design that allows the a system, set up , program or lab and others to be
accessible by many users, this design allows broad range of abilities, reading levels as well as learning styles and ages and others to have access to particular set up or program.
it gives encouragment to the development of ICTS which can be
usable as well as accessible to the widest range of people.
convert decimal number into binary numbers (265)10
Answer:
HELLOOOO
Alr lets start with steps by dividing by 2 again and againn..
265 / 2 = 132 ( rem = 1 )
132 / 2 = 66 ( rem = 0 )
66/2 = 33 ( rem = 0 )
33/2 = 16 ( rem = 1 )
16/2 = 8 ( rem = 0 )
8/2 = 4 ( rem = 0 )
4/2 = 2 ( rem = 0 )
2/2 = 1 ( rem = 0 )
1/2 = 0 ( rem = 1 )
now write all the remainders from bottom to up
100001001
is ur ans :)))
How many cost units are spent in the entire process of performing 40 consecutive append operations on an empty array which starts out at capacity 5, assuming that the array will grow by a constant 2 spaces each time a new item is added to an already full dynamic array
Answer:
Explanation:
260 cost units, Big O(n) complexity for a push
You are going to purchase (2) items from an online store.
If you spend $100 or more, you will get a 10% discount on your total purchase.
If you spend between $50 and $100, you will get a 5% discount on your total purchase.
If you spend less than $50, you will get no discount.
Givens:
Cost of First Item (in $)
Cost of Second Item (in $)
Result To Print Out:
"Your total purchase is $X." or "Your total purchase is $X, which includes your X% discount."
Answer:
Code:-
using System;
using System.Collections.Generic;
class MainClass {
public static void Main (string[] args) {
int Val1,Val2,total;
string input;
double overall;
Console.Write("Cost of First Item (in $)");
input = Console.ReadLine();
Val1 = Convert.ToInt32(input);
Console.Write("Cost of Second Item (in $)");
input = Console.ReadLine();
Val2 = Convert.ToInt32(input);
total=Val1+Val2;
if (total >= 100)
{
overall=.9*total;
Console.WriteLine("Your total purchase is $"+overall);
}
else if (total >= 50 & total < 100)
{
overall=.95*total;
Console.WriteLine("Your total purchase is $"+overall);
}
else
{
Console.WriteLine("Your total purchase is $"+total);
}
}
}
Output:
explain the elements of structured cabling systems
Answer:
From this article, we can know that a structured cabling system consists of six important components. They are horizontal cabling, backbone cabling, work area, telecommunications closet, equipment room and entrance facility.
dismiss information I have here and hope you like it and hope you will get this answer helpful and give me the thankyou reactions
what is computer? write about computer.
Answer:
Is an electronic device used for storing and processing data.
Write a class of complex numbers consisting of:
-Properties:
• Real part of type double;
• Virtual part of type double.
- Method:
• default constructor, 2-parameter constructor;
• Full setter, getter for each variable;
• the print() function prints SoPhuc as a string in the format a + bi, where a is the real part, b is the imaginary part
-Write main() function:
• Create 2 SoPhuc objects
• Use class methods to enter information for 2 objects
• Use print() method to print information of 2 objects that have been created
Answer:
hi sorry for not knowing the answer
but please follow have a great day,night, or afternoon
Many Java programs that you create will receive and process user input. In order to ensure that user input is accurate, you will need to use input validation and exception handling.
a. True
b. False
Answer: True
Explanation: True
1. Create a pseudocode program that asks students to enter a word. Call a function to compute the different ways in which the letters that make up the word can be arranged.
2. Convert the pseudocode in question one to JavaScript and test your program.
Answer:
1)Pseudocode:-
Prompt user to enter string
Pass it to combination function which can calculate the entire combination and can return it in an array
In combination method -
Check if the string is length 2 size ie of 0 or 1 length then return string itself
Else iterate through string user entered
Get the present character within the variable and check if the variable is already used then skip
Create a string from 0 to i the index + (concatenate) i+1 to length and recursive call combination function and pass this string and store end in subpermutation array
For each recursive call push character + sub permutation in total arrangement array.
2)Code -
function combinations(userStr) {
/* when string length is less than 2 then simply return string */
if (userStr.length < 2) return userStr;
/* this array will store number of arrangement that word can be stored */
var totalArrangements = [];
/* iterate through string user enter */
for (var i = 0; i < userStr.length; i++) {
/* get the current character */
var character = userStr[i];
/*check if character is already used than skip */
if (userStr.indexOf(character) != i)
continue;
/* create a string and concanete it form 0 to i index and i+1 to length of array */
var str = userStr.slice(0, i) + userStr.slice(i + 1, userStr.length);
/* push it to totalArrangments */
for (var subPermutation of combinations(str))
totalArrangements.push(character + subPermutation)
}
/* return the total arrangements */
return totalArrangements;
}
/* ask user to prompt string */
var userStr = prompt("Enter a string: ");
/* count to count the total number of combinations */
let count = 0;
/* call function the return tolal number of arrangement in array */
totalArrangements = combinations(userStr);
/* print the combination in console */
for (permutation of totalArrangements) {
console.log(permutation)
}
/* total combination will be totalArrangements.length */
count = totalArrangements.length;
/*print it to console */
console.log("Total combination " + count)
Output:-
Which is the first computer brought in nepal for the census of 2028 B.S
Answer:
The first computer brought in Nepal was IBM 1401 which was brought by the Nepal government in lease (1 lakh 25 thousands per month) for the population census of 1972 AD (2028 BS). It took 1 year 7 months and 15 days to complete census of 1crore 12.5 lakhs population.
The trackpad/touchpad on my laptop is acting unusual. When I click on something or move to an area, it jumps or moves to another area. What would be a good troubleshooting step to try and resolve this issue?
a. Use a mouse instead
b. Remove all possible contact points, and test again while ensuring only a single contact point
c. Refer caller to user guides
d. increase the brightness of the display
Answer:
My best answer would be, "b. Remove all possible contact points, and test again while ensuring only a single contact point"
This is because usually when the cursor jumps around without reason, it's caused by the user accidentally hitting the mouse touchpad on his or her laptop while typing. ... Similarly, know that just because you have an external mouse attached to your laptop, the built-in mousepad is not automatically disabled.
Brainliest?