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
Phantasy [73]
3 years ago
13

Given the code segment below, complete the assignments as stated in the comments. struct aaa { int m; int nn; } struct bbb{ stru

ct aaa myfield; int sum; } struct bbb myvar; // write one statement to place the integer value 44 into the field sum of structure variable myvar . // write one statement to place the integer value -17 into the field nn of structure variable myvar .
Computers and Technology
1 answer:
grin007 [14]3 years ago
6 0

Answer:

  1. using namespace std;
  2. struct aaa {
  3.    int m;
  4.    int nn;
  5. };
  6. struct bbb{
  7.    struct aaa myfield;
  8.    int sum;  
  9. };
  10. struct bbb myvar;
  11. int main()
  12. {
  13.    myvar.sum =44;
  14.    myvar.myfield.nn = -17;
  15.    
  16.    cout<<myvar.sum<<"\n";
  17.    cout<<myvar.myfield.nn<<"\n";
  18.    return 0;
  19. }

Explanation:

Given two data structures (Line 2-9), we can set the value of 44 to field of sum structure variable myvar by using a dot syntax

                      myvar.sum = 44

To assign value to field of nn of structure in myvar, we need to access the myfield of myvar and then followed by nn. Hence, the statement shall be

                     myvar.myfield.nn = -17

In short the we can always use the dot syntax the access the value of an inner field of a particular data structure.

You might be interested in
You plug a new scanner into a USB port on your Windows system. When you first turn on the scanner, what should you expect to see
Paul [167]

Answer:

A window notifying that: Found New Hardware Wizard

Explanation:

As soon as any device is plugged into the USB port, the default settings will display a window onto the screen which will notify about the addition of a new hardware to the system. This window can further be used to know the properties of the hardware or for configuration settings.

This process is same like the software part, that whenever a new application is installed onto the system a pop up notification alerts about its presence.

So when the scanner will be attached through USB port a window will be appeared notifying about the discovery of new hardware.

3 0
3 years ago
Write a for loop to print all NUM_VALS elements of array hourlyTemp. Separate elements with a comma and space. Ex: If hourlyTemp
kondaur [170]

in c++

...

for(auto& el:hourlyTemp){

std::cout<<el<<", ";

}

...

This is called Range-based loop or for each loop

5 0
3 years ago
Which of the following is a sign that a website is inappropriate?
nata0808 [166]

Answer:

A

Explanation:

If you find something embarrassing, its more likely that other people with also think its embarrassing. All the other points are on the internet right now. Amazon sells things, News show information and there are political campaigns to show you there offers

3 0
3 years ago
Read 2 more answers
Which html attributes are required in the image () element - check as many as apply
kotykmax [81]

Answer:

The correct answer for the given question is option(3) i.  src.

Explanation:

In HTML if we insert a image on the screen we use<img> tag

the img have following attribute

1.src

2.height.

3 alt

4 width

The required attribute in img tag is src i.e source or path of image

The following are the syntax of image tag

<img src=" path of image" alt="not visible"  height="100px" width="100px"/>

The height and width attribute describe the height and width of image in pixel.

The alt attribute is not mendatory attribute in image tag.The alt attribute display the message when image is not visible in the web page .

All the other attribute like alt,height,width are used as per the requirement but src is an required attribute .

so the option(3) is correct.

6 0
3 years ago
PLEASE HELP ASAP!! WILL MARK BRAINLIEST!! 20 POINTS!!
Sonbull [250]

Answer:

kiss me

Explanation:

you must kiss me

8 0
3 years ago
Other questions:
  • Write a function, factors, that takes an integer n, and returns a list of values that are the positive divisors of n. Note: 0 is
    13·1 answer
  • In excel what does sidney need to consider when creating formulas
    7·1 answer
  • Consider what fact-finding techniques you would use to identify the important facts needed to develop a database system. Please
    7·1 answer
  • Explain Cascading Style Sheets and what they do. Describe their primary function, two effects that this function has on programm
    11·1 answer
  • To aid Android app developers, who must account for multiple screen sizes and resolutions, Android has introduced the ____, whic
    15·1 answer
  • IT investments can lead to developing IT capabilities and dynamic IT competencies, which can lead to achieving the following six
    5·1 answer
  • Why do TV shows/Movies from the 90's and early 2000s look so much different compared to today?
    7·1 answer
  • As technology advances, does technology become more of less complex?
    14·1 answer
  • You manage a network that uses a single switch. All ports within your building connect through the single switch. In the lobby o
    14·1 answer
  • Do anyone know how to code like I need someone do a code for me?
    13·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!