1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
pickupchik [31]
3 years ago
9

1. An integer in C (int) is represented by 4 bytes (1 byte = 8 bits). Find the largest integer that can be handled by C. Verify

that number by computer (try to printf that number, and printf that number +1). No programming is required for this. Hint: (a) Conversion from binary to decimal: 3 2 1 0 2 1101 =1 2 + 0 2 +1 2 +1 2 = 8 + 0 + 2 +1 10 =11 (b) If an integer is represented by 1 byte (8 bits), the maximum integer number is 1111111 (Seven 1's as one bit must be reserved for a sign). 6 5 0 2 1111111 =1 2 +1 2 ++1 2 1 2 1 7 =  − =128 −1 (c) The number looks like a telephone number in Dallas.
Computers and Technology
1 answer:
faust18 [17]3 years ago
4 0

Answer:

Check the explanation

Explanation:

In C, int requires 4 butes to sotre a integer number. that means it requires 4*8 = 32 bits. The maximum number can be stored using 32 bits is

(11111111111111111111111111111111)_2

The first digit is used for sign. decimal equivalent to this number can be computed as

(1111111111111111111111111111111)_2= 1\times2^{30}+1\times2^{29}+...+1\times2^0

=1\times2^{31}-1

= 2147483647-1=2147483646

That means int can store a up to 2147483646.

                      Testing with C code

#include<stdio.h>

int main()

{

  int a = 2147483647; // a with max number

  printf("%d\n",a);// printing max number

  a = a+1;// adding one to the number

  printf("%d\n",a);// printing the number after adding one

  return 0;

}

                THE OUTPUT

$ ./a.out

2147483647

-2147483648

You might be interested in
A standard for compressing music into computer files that can be easily exchanged on the Internet is called a(n) ______. A. musi
Sophie [7]

Answer:

The correct answer is E. MP3

Explanation:

MP3 (formally MPEG-1 Audio Layer III or MPEG-2 Audio Layer III) is a coding format for digital audio. MP3 as a file format commonly designates files containing an elementary stream of MPEG-1 audio and video encoded data, without other complexities of the MP3 standard. The MP3 format makes it possible to compress a song into a file small enough to be uploaded, downloaded, emailed, and stored on a hard drive.

4 0
3 years ago
Can someone tell me what this means Higfaa
Arisa [49]

Answer:

it's a Jamaican slang

Explanation:

it depends on the wah it is used

7 0
2 years ago
What is the different between 32bit anf 64 bit verision​
Elina [12.6K]

<u>The different between 32 bit and 64 bit version:​</u>

  • The main difference between 32-bit and 64-bit versions is that a 32-bit version can access 2^3^2 memory addresses which is roughly equivalent to 4 GB of memory.
  • On the other hand, a 64-bit version can access 2^6^4 memory addresses which equates to a huge amount of memory, 16 exabytes to be precise.  
  • Nowadays, we observe that almost all the computers have 64-bit processors, which means that they can access any amount of memory over 4 GB till 16 exabytes.
  • 64-bit processors have various advantages like the increased speed of operations, smooth multitasking and they can also support video games and software's that have high graphical requirements.
8 0
3 years ago
Brake fluid is made up of a chemical that:
TEA [102]

A) IS MOSTLY JUST ENGINE Oil.

7 0
3 years ago
Read 2 more answers
When a primary key combines two or more fields, it is called a ____ key?
Tanya [424]
<span>When a primary key combines two or more fields, it is called a ____ key
the answer is Constructed key</span>
6 0
2 years ago
Other questions:
  • You can apply several different worksheet themes from which tab?
    11·2 answers
  • Categories of general purpose application software and examples each​
    13·1 answer
  • IPv6 can use a DHCPv6 server for the allocation of IPv6 addressing to hosts. Another IPv6 addressing option utilizes the IPv6 Ne
    10·1 answer
  • In one sentences describe how to change your home page
    10·1 answer
  • Technician A says that to cover all possible vehicle conditions, coolant must have a high freezing point. Technician B says cool
    6·2 answers
  • The 7-bit ASCII code for the character ‘&amp;’ is: 0100110 An odd parity check bit is now added to this code so 8 bits are trans
    12·1 answer
  • The HTTP protocol operates at which layer?
    7·1 answer
  • Being nice take the points​
    9·1 answer
  • Please its argent and I will give you BRAINLIEST ANSWER 6. How would you confirm that a colourless liquid given to you is pure w
    10·1 answer
  • PLEASE HELP FIRST ONE TO ANSWER WILL GET BRAINLIEST!!
    10·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!