Answer:
4 bits:
6 = 0110
-6 = 1010
8 bits:
6 = 00000110
-6 = 11111010
Explanation:
2's complement is easier to implement, because it only has one representation of 0 and starts counting backwards from the highest number you can represent with the available bits.
e.g.,
7 = 0111
6 = 0110
5 = 0101
4 = 0100
3 = 0011
2 = 0010
1 = 0001
0 = 0000
-1 = 1111
-2 = 1110
-3 = 1101
-4 = 1100
-5 = 1011
-6 = 1010
For 4 bits:
-6 = 01106 = 1010For 8 bits (1 byte):
-6 = 0000 + 0110 = 000001106 = 1111 + 1010 = 11111010What is binary encoding?Binary encoding can be defined as a standard technique that is designed and developed to convert data in plain text (source alphabets) to a form that is easily used by different operating systems (OS), especially through the use of a binary digit (bit) or two-symbol system.
The two’s complement of base-10.In Computer programming, two's complement of base-10 is generally easier to implement because it has a single representation of 0 only.
Decimal Two’s Complement Decimal Two’s Complement
0 0000 0 0000
1 1111 1111 -1 0000 0001
2 1111 1110 -2 0000 0010
3 1111 1101 -3 0000 0011
4 1111 1100 -4 0000 0100
5 1111 1011 -5 0000 0101
6 1111 1010 -6 0000 0110
7 1111 1001 -7 0000 0111
8 1111 1000 -8 0000 1000
For 4 bits:
-6 = 0110
6 = 1010
For 8 bits (1 byte):
-6 = 0000 + 0110 = 00000110
6 = 1111 + 1010 = 11111010
Read more on binary encoding here: https://brainly.com/question/5381889
importance of ethical rules in new technologies?
Answer:
Ethical rules in the sphere of all technologies are imperative.
Explanation:
Ethical rules for technologies limit the information gathered, what can be done with the gathered data, the disclosure of what is collected and used/sold, and the restriction of technology that is dangerous to humans (bio-technologies).
1.) Which three Windows 10 editions allow you to restrict updates to only security updates?
2.) Which method of backing up system files was available in Windows 7 and is now available again in Windows 10?
3.) Following a failed attempt to upgrade Windows 8 to Windows 10, which two folders on drive D: might contain log files to help you troubleshoot the problem when Windows setup files are stored on drive D:?
4.) Under what circumstances might the product key for Windows be stored on firmware on the motherboard?
5.) Windows 10 has become corrupted and you decide to reinstall the OS. Will the setup process request a product key during the install? Why or why not?
Answer:
1. Windows 10 Pro, Windows 10 Enterprise, Windows 10 Education.
2. Backup and Restore Center
3. I'm not sure
4. I'm not sure
5. Yes it will ask for it, but you'll have the option to choose to do it later. When you are loaded into Windows, it will automatically detect your computer and activate. The reason for this is that you might be trying to download a new version of Windows such as Pro.
14. My computer “boots-up” (aka activates and starts running) but it tells me that it cannot find the data to start the operating system, and I hear a subtle clicking noise coming from my computer. What physical component of the computer do you believe is defective? Defend your answer.
For this computer, the hard drive is the physical component that is defective.
What is a physical component?A physical component can be defined as a component (hardware) of an computer system or information technology (IT) that can be seen and touched.
The physical components of a computer.Some examples of the physical components of a computer system include:
MotherboardCentral processing unit (CPU)KeyboardMonitorMouseHard driveThe hard drive refers to an electromagnetic data storage device that is typically used for storing and retrieving digital data such as an operating system (OS) on a computer system.
Generally, a computer would make a subtle clicking noise when it finds it difficult to read or retrieve the data stored on its hard drive.
Read more on physical components here: brainly.com/question/959479
Write a program to calculate the angle of incidence (in degrees) of a light ray in Region 2 given the angle of incidence in Region 1 and the indices of refraction n1 and n2. (Note: If n2>n1, then for some angles 1, Equation 2 will have no real solution because the absolute value of the quantity will be greater than 1. When this occurs, all light is reflected back into Region 1, and no light passes into Region 2 at all. Your program must be able to recognize and properly handle this condition.) The program should also create a plot showing the incident ray, the boundary between the two regions, and the refracted ray on the other side of the boundary. Test your program by running it for the following two cases: (a) n1= 1.0, n2 = 1.7, and 1= 45°. (b) n1 = 1.7, n2 = 1.0; and 1= 45°
The program is an illustration of conditional statements
What are conditional statements?conditional statements are statements that are used to make decisions
The main programThe program written in Python, where comments are used to explain each line is as follows
#This imports the math module
import math
#This get sthe refraction index 1
n1 = float(input("Refraction index 1: "))
#This get sthe refraction index 2
n2 = float(input("Refraction index 2: "))
#This gets the normal angle of incidence in region 1
theta1 = float(input("Normal of incidence in region 1 (degrees): "))
#If n1 is greater than n2, then there is no real solution
if n1 > n2:
print("No real solution")
#If otherwise
else:
#This calculates the angle of incidence
theta2 = math.asin(n1/n2 * math.sin(math.radians(theta1))) * (180/math.pi)
#This prints the angle of incidence
print("Angle of incidence",round(theta2,2),"degrees")
Note that the program only calculates the angle of incidence, it does not print the plot
Read more about conditional statements at:
https://brainly.com/question/24833629
( _____)once demonstrated that a rigid wing on an aircraft would break more often than a flexible wing. Will give BRAINLIEST.
Answer:
the Wright brothers
Explanation:
Wing warping was an early system for lateral (roll) control of a fixed-wing aircraft. The technique, used and patented by the Wright brothers, consisted of a system of pulleys and cables to twist the trailing edges of the wings in opposite directions.
Answer:
the Wright Brothers
Explanation:
I know
How is technology powerless?
Answer:
Bluetooth
Explanation:
I am not fully aware of what the full quisten is but I think this is the answer you are looking for
Which is an advantage of a computer network?
A. Networked computers can process data and run software faster than single computers.
B. Networks prevent unauthorized access to data and protect equipment.
C. Networked computers are less likely than single computers to suffer equipment failure.
D. Networks allow computers to connect quickly and to share data or equipment.
D. is the answer.............
Given the user inputs, complete a program that does the following tasks: Define a set, fruits, containing the user inputs: my_fruit1, my_fruit2, and my_fruit3. Add the user inputs, your_fruit1 and your_fruit2, to fruits. Add the user input, their_fruit, to fruits. Add your_fruit1 to fruits. Remove my_fruit1 from fruits. Observe the output of each print statement carefully to understand what was done by each task of the program. Note: For testing purposes, sets are printed using sorted() for comparison, as in the book's examples. Ex: If the input is:
The program is an illustration of sets in a python program
What are sets?Sets are variables that hold multiple values in a program
The main programThe program written in Python, where comments are used to explain each line is as follows:
my_fruit1 = input()
my_fruit2 = input()
my_fruit3 = input()
your_fruit1 = input()
your_fruit2 = input()
their_fruit = input()
# 1. TODO: Define a set, fruits, containing my_fruit1, my_fruit2, and my_fruit3
fruits = {my_fruit1, my_fruit2, my_fruit3}
print(sorted(fruits))
# 2. TODO: Add your_fruit1 and your_fruit2 to fruits
fruits.add(your_fruit1)
fruits.add(your_fruit2)
print(sorted(fruits))
# 3. TODO: Add their_fruit to fruits
fruits.add(their_fruit)
print(sorted(fruits))
# 4. TODO: Add your_fruit1 to fruits
fruits.add(your_fruit1)
print(sorted(fruits))
# 5. TODO: Remove my_fruit1 from fruits
fruits.remove(my_fruit1)
print(sorted(fruits))
Read more about python programs at:
https://brainly.com/question/26497128
why are men more exposed to mass media?
Answer:
because they like exploring
Why do we use for loops with arrays?
Group of answer choices
For loops let us access one specific element of an array.
Lets us quickly process contents of the array.
To store one piece of data at a time.
For loops let Python handle the values as strings not numbers.
Which of the formulas below are valid? Select all that apply?
Answer:
Is there a picture to go with this question?
Explanation:
Is there a picture to go with this question?
Write a program that does the following:
You will make a program that registers the maximum TEMPERATURE that is registered during the WEEK (that is, every day, that is, 7 days).
You must at the end show/print the number of temperatures that were HOT (May or equal to 25 degrees) and those that were COLD (less than or equal to 10 degrees)
The program MUST have DO WHILE and IF.
IN JAVA SCRIPT AND PLEASE SEND THE CODE IN THE COMMENTS
Answer:
Mean maximum temperature is measured by taking maximum temperatures and add them up and divide again by as many as the mean highest temperatures you added up. One measures the mean of only highest temperatures and the other the average of all high temperatures.
Explanation:
A packet contains three parts: header, payload, and trailer.
Choose the answer.
True
False
Answer:
True
Explanation:
I took the quiz
A virus is NOT a software * True or False
Answer:
false
Explanation:
Note : Each question carry three parts (A), (B), (C) out of
which attempt any two parts. All questions carry
equal marks.
1. (A) What do you mean by computer? Discuss the use of
computer in daily life.
(B) Differentiate between computer hardware & Software.
(C) Describe about the different types of computer
peripherals and memory devices.
2. (A) What is a printer? Explain different types of printer.
(B) What are scanning devices? Explain any four scan-
ning devices.
(C) What is CPU? Discuss components of CPU.
Answer:
1)a)the electronic device that helps us to read write listen music entertainment play games etc.Use of computer in our life is incredibly necessary. ... Computers have taken industries and businesses to a worldwide level. They are used at home for online education, entertainment, in offices, hospitals, private firms, NGOs, Software house, Government Sector Etc.
b)Hardware is a physical parts computer that cause processing of data. Software is a set of instruction that tells a computer exactly what to do. ... Hardware can not perform any task without software. software can not be executed without hardware.
c)Personal Computer (PC)
2 Workstation
3 Minicomputer
4 Main Frame
2)a)Printers are one of the common computer peripheral devices that can be classified into two categories that are 2D and 3D printers.Laser Printers.
Solid Ink Printers.
LED Printers.
Business Inkjet Printers.
Home Inkjet Printers.
Multifunction Printers.
Dot Matrix Printers.
3D Printers.
b)an electronic device which scans artwork and illustrations and converts the images to digital form for manipulation, and incorporation into printed
c)A central processing unit, also called a central processor, main processor or just processor, is the electronic circuitry that executes instructions comprising a computer program.
convert 34.657 to binary and also 25.75 to binary
Answer:
34.657=100010.1010100000110001001 base two
25.75 =11001.11
Today
ABCDEFGH. What letter comes three to the right of the
letter that comes immediately to the left of the letter
that comes three to the right of the letter immediately
to the left of the letter B?
Answer:
Ourr letter is D. On three positions right, the letter is G. → Thus, our answer is G. So, G is the letter which is three to the right of the letter immediately to the left of the letter three to the left of the letter two to the right of letter F.
Explanation: hope it helps friend
In other programming languages, the dictionary data structure is referred to as a(an)
Answer:
hash
Explanation:
it is called a hash, a map, or a hasmap
Each Internet location has a unique______address.
Choose the answer.
TCP
RAM
OSI
IP
Answer:
IP
Explanation:
Whenever you are connected to the Internet always you have two ip addresses. Your public ip and your private ip. Your ip address has to be unique for you to access the Internet. For example, if you have multiple computers within your home, they most likely each have their own private IP address.
#include <iostream>
using namespace std;
int main()
{
int num1, num2,r,i;
cout<<"Enter a start: ";
cin>>num1;
cout<<"Enter an end: ";
cin>>num2;
cout<<"\n\nODD NUMBERS\n";
for(i=num1; i<=num2; i++){
r=i%2;
if(r==1)
cout<<" "<<i;
}
cout<<"\nEVEN NUMBERS\n";
for(i=num1; i<=num2; i++){
r=i%2;
if(r==0)
cout<<" "<<i;
}
if(num1>num2){
cout<<"ERROR! Starting Number is GREATER THAN the Ending Number!!!";
return 0;
}
}
Using while loop, do while and for loop write a C++ program that lets you input a starting and ending integer (range) then display all the odd integers and the even integers within the range then compute the sum of each set of integers.:
If the starting number is greater than ending number, the program should display “ERROR! Starting Number is GREATER THAN the Ending Number!!!”.
Sample output:
Enter a start: 1
Enter an end: 10
ODD NUMBERS
1 3 5 7 9 Sum: 25
EVEN NUMBERS
2 4 6 8 10 Sum: 30
the attached pic has been my progress so far. please help me reach the expected output.
Explanation:
...........................
Name three reasons why computers use both integers and real numbers
Answer:
Precision, readability, and appropriateness
one example of requirement verification techniques
Answer:
The four fundamental methods of verification are Inspection, Demonstration, Test, and Analysis. The four methods are somewhat hierarchical in nature, as each verifies the requirements of a product or system with increasing rigor.
Explanation:
Designing a medium to large network requires a combination of technologies and there isn't one "right way." Think about the technologies you would need to deploy to implement a college campus network with multiple buildings, hundreds of faculty and staff, and dozens of computer-equipped - classrooms and labs. Think of the ancillary technologies you might need to integrate into the network such as data projectors, smart whiteboards, campus security systems, and so forth. Consider consulting with the IT staff at your school or another school to see what technologies they use. Instructions: Write a post of at least four paragraphs outlining the technologies you would use to connect student and faculty computers, servers, multiple buildings and so forth.
Technology allows for easy accessibility, communication and information technology could connect student and faculty computers and servers.
What is computer networking?It is the ability of computers to communicate with one another. It makes use of a communication technology that would allow different computers to be connected to each other.
Technologies that will be used include,
Communication technologyInformation technologyThe different types of networking systems that can be used for communication and information include,
Local area networkWide area networkComputer area networkLocal Area Network (LAN): It is a computer network that can be used in a small confined area such as a school, laboratory, office, or group of buildings.
Thererfore, technologies you would use to connect student and faculty computers, servers, multiple buildings include communication and information technology.
Learn more on technology here,
https://brainly.com/question/23418761
please give all the answer
Why do i do this XD trolling be like
Answer:
Explanation:
Her computer is always freezing. Just __________ again and it should work
Answer:
restart
Explanation:
i think it will help it
#Python: The given program reads a list of single-word first names and ages (ending with -1), and outputs that list with the age incremented. The program fails and throws an exception if the second input on a line is a string rather than an integer. At FIXME in the code, add try and except blocks to catch the ValueError exception and output 0 for the age.
Ex: If the input is:
Lee 18
Lua 21
Mary Beth 19
Stu 33
-1
then the output is:
Lee 19
Lua 22
Mary 0
Stu 34
"# Split input into 2 parts: name and age
parts = input().split()
name = parts[0]
while name != '-1':
# FIXME: The following line will throw ValueError exception.
# Insert try/except blocks to catch the exception.
age = int(parts[1]) + 1
print('{} {}'.format(name, age))
# Get next line
parts = input().split()
name = parts[0]"
The program illustrates the use of catching exceptions.
What are exceptions?Exceptions are program statements that are used to control program errors, and prevent a program from crashing.
How to fix write the exceptionThe statements that catch the exception in the program are:
try:
age = int(parts[1]) + 1
print('{} {}'.format(name, age))
# Get next line
parts = input().split()
name = parts[0]
except ValueError:
print('Invalid value!')
# Get next line
parts = input().split()
name = parts[0]
The complete programThe complete program is as follows:
# Split input into 2 parts: name and age
parts = input().split()
name = parts[0]
while name != '-1':
# FIXME: The following line will throw ValueError exception.
# Insert try/except blocks to catch the exception.
try:
age = int(parts[1]) + 1
print('{} {}'.format(name, age))
# Get next line
parts = input().split()
name = parts[0]
except ValueError:
print('Invalid value!')
# Get next line
parts = input().split()
name = parts[0]
Read more about program exceptions at:
https://brainly.com/question/25012091
11. In cell R9, enter a formula using the AVERAGE function and structured references to determine the average number of years of post-secondary education of all students as shown in the Post-Secondary Years column.
The typical AVERAGE function that can be used to determine the average number of years of post-secondary education of all students is "AVERAGE(StudentRepresentatives[Post-Secondary Years])".
What is an AVERAGE function?In a spreadsheet, the AVERAGE function is used to find the normal average of a list of data, such as the total list of population.
In conclusion, the function "AVERAGE(StudentRepresentatives[Post-Secondary Years])" will be used to determine the average number of years.
Read more about AVERAGE function
brainly.com/question/2263994
Create a class RightTriangle which implements the API exactly as described in the following JavadocLinks to an external site..
Don't forget - you will need to use the Pythagorean theorem (Links to an external site.) to find the hypotenuse (and therefore the perimeter) of a right triangle. You can find the area of a right triangle by multiplying the base and height together, then dividing this product by 2.
Use the runner_RightTriangle file to test the methods in your class; do not add a main method to your RightTriangle class.
Hint 1 - Javadoc only shows public methods, variables and constructors. You will need to add some private member variables to your RightTriangle class to store the necessary information. Think carefully about what information actually needs to be stored and how this will need to be updated when methods change the state of a RightTriangle object.
Hint 2 - As in the previous lesson's exercise it's helpful to add your method/constructor headers and any dummy returns needed before implementing each one properly. This will allow you to test your code using the runner class as you go along.
This is the runner code:
import java.util.Scanner;
public class runner_RightTriangle{
public static void main(String[] args){
Scanner scan = new Scanner(System.in);
RightTriangle t = new RightTriangle();
String instruction = "";
while(!instruction.equals("q")){
System.out.println("Type the name of the method to test. Type c to construct a new triangle, q to quit.");
instruction = scan.nextLine();
if(instruction.equals("getArea")){
System.out.println(t.getArea());
}
else if(instruction.equals("getBase")){
System.out.println(t.getBase());
}
else if(instruction.equals("getHeight")){
System.out.println(t.getHeight());
}
else if(instruction.equals("getHypotenuse")){
System.out.println(t.getHypotenuse());
}
else if(instruction.equals("getPerimeter")){
System.out.println(t.getPerimeter());
}
else if(instruction.equals("toString")){
System.out.println(t);
}
else if(instruction.equals("setBase")){
System.out.println("Enter parameter value:");
double arg = scan.nextDouble();
t.setBase(arg);
scan.nextLine();
}
else if(instruction.equals("setHeight")){
System.out.println("Enter parameter value:");
double arg = scan.nextDouble();
t.setHeight(arg);
scan.nextLine();
}
else if(instruction.equals("equals")){
System.out.println("Enter base and height:");
double bs = scan.nextDouble();
double ht = scan.nextDouble();
RightTriangle tOther = new RightTriangle(bs, ht);
System.out.println(t.equals(tOther));
scan.nextLine();
}
else if(instruction.equals("c")){
System.out.println("Enter base and height:");
double bs = scan.nextDouble();
double ht = scan.nextDouble();
t = new RightTriangle(bs, ht);
scan.nextLine();
}
else if(!instruction.equals("q")){
System.out.println("Not recognized.");
}
}
}
}
My code so far:
class RightTriangle{
private double base;
private double height;
public RightTriangle(){
base = 1.0;
height = 1.0;
}
public RightTriangle(double ds, double ht){
base=ds;
height=ht;
}
public boolean equals(RightTriangle other){
if(base==other.base && height==other.height ){
return true;
}
else
{
return false;
}
}
public double getArea()
{
return (base*height)/2;
}
public double getBase(){
return base;
}
public double getHeight()
{
return height;
}
public double getHypotenuse()
{
return Math.sqrt((base*base)+(height*height));
}
public double getPerimeter()
{
return base+height+Math.sqrt((base*base)+(height*height));
}
void setBase (double bs)
{
if(bs==0){
System.exit(0);
}
else{
base=bs;
}
}
public void setHeight(double ht){
if(ht==0){
System.exit(0);
}
height=ht;
}
public java.lang.String toString()
{
return "base: "+base+" hegiht: "+height+" hypothesis: "+ Math.sqrt((base*base)+(height*height));
}
}
MY CODE SAYS THAT THE setHeight and setBase and toString METHODS ARE INCORRECT.
Answer:
I don't see anything. Its blank
Explanation:
An array of integers can be assigned to a memory address in the ...
An array of integers can be assigned to a memory address in the .datanumbers
section of a MIPS assembly language program as show below. Here the length of the array is stored first, and then the elements of the array next.
Implement a MIPS assembly language program to perform the functionality of the following C program and print the updated array content, by listing each integer in it.
It should ask a user to enter three integers, a starting index, an ending index, and an integer to use for a comparison. It should examine only the elements in the array located from the entered starting index, to the entered ending index to check if each of them is greater the last entered integer, then if it is, subtract 3*the last entered integer to each such element in the array.
For instance, if a user enters 2, enters 9, then enters 3, then the output will be the following:
45
-6
14
-7
6
-17
2
-4
14
-26
2
19
i.e., the numbers that are located between the index 2 and 9 are examined to see if each of them is greater than the last entered number (3 in this case),
then each of such element is subtracted with 3 times that number (3 in this case) if it is.
If the entered ending index is larger than 11, then the program should exam elements in the array until the end, and if the entered starting index is less than 0, then it should start examining elements from the first one in the array.
.data
numbers_len: .word 12
numbers: .word 45, -6, 23, -7, 15, -17, 11, -4, 23, -26, 2, 19}
The following shows how it looks like in a C program:
int numbers[12] = {45, -6, 23, -7, 15, -17, 11, -4, 23, -26, 2, 19};
int startIndex, endIndex, num1;
int j;
printf("Enter a starting index:n");
//read an integer from a user input and store it in startIndex
scanf("%d", &startIndex);
printf("Enter an ending index:n");
//read an integer from a user input and store it in endIndex
scanf("%d", &endIndex);
printf("Enter an integer:n");
//read an integer from a user input and store it in num1
scanf("%d", &num1);
if (startIndex < 0)
startIndex = 0;
for (j = startIndex; j <= endIndex && j < 12; j = j+1)
{
if (numbers[j] > num1)
{
numbers[j] = numbers[j] - (3 * num1);
}
}
printf("Result Array Content:n");
for (j = 0; j < 12; j = j+1)
{
printf("%dn", numbers[j]);
}
The following is a sample output (user input is in bold):
Enter a starting index:
2
Enter an ending index:
9
Enter an integer:
3
Result Array Content:
45
-6
14
-7
6
-17
2
-4
14
-26
2
19
Please make sure it can output like the sample above
Answer:
A :)
Explanation: