How will this difference b interpreted, Computer Engineering

Assignment Help:

How will this difference b interpreted?

When one pointer is subtracted from another pointer, the number of elements between the two pointers always includes the element pointed to by one of the pointers. As an example, for s_ptr2 - s_ptr1, the difference is 3.

Subtracting s_ptr1 from s_ptr2 yields the number of elements between the two pointers: 3 elements. The compiler subtracts the addresses of the two pointers and divides the result (6 bytes) by the size of the pointed-to object. In this example, the compiler divides by 2 bytes (sizeof(short)).

 

 


Related Discussions:- How will this difference b interpreted

Grapgh, representation of the adjacency matrix and adjacency list

representation of the adjacency matrix and adjacency list

Determine what part of global array to work on thread number, Q. Determine ...

Q. Determine what part of global array to work on thread number? #include void subdomain(float x[ ], int istart, int ipoints) { int i; for (i = 0; i x[istart+

Communication traffic and message queues, The Communication Traffic gives a...

The Communication Traffic gives a pictorial view of the communication traffic in the interconnection network with respect to the time in progress. The Communication Traffic shows t

What happens if a function module runs in an update task, What happens if a...

What happens if a function module runs in an update task? The system performs the module processing asynchronously.  Instead of carrying out the call immediately, the system w

What is the function of the correction system, What is the function of the ...

What is the function of the correction system? The correction system handles changes to internal system components. Like as objects of the ABAP/4 Dictionary.

How future environment changes can be predicted - simulation, How future cl...

How future climate/environment changes can be predicted -  Information over time is fed into a weather/climate model -  based on changes in weather patterns, carries out a s

What is memory controller, What is memory controller? A memory controll...

What is memory controller? A memory controller is a circuit which is interposed among the processor and the dynamic memory. It is used for performing multiplexing of address bi

Objectives of parallel computing, Objectives of Parallel Computing Aft...

Objectives of Parallel Computing After reading this topic, you would be able to: Tell historical details of parallel computing; Explain the fundamental ideas of dis

Differentiate among validation and exception testing, Differentiate between...

Differentiate between validation and exception testing. - Validation testing is done to test software in conformance to requirements specified. It aims to demonstrate that soft

Explain about the term- reports, Explain about the term- Reports Repor...

Explain about the term- Reports Reports are produced as a result of questions like "how many times has a type of car broken down" or "which cities have the highest house price

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd