Question:
C programming struct question?
Kayoz
2009-02-15 16:47:48 UTC
Need help with C Programming?
3) Floating point struct


Define a struct Single that describes the memory layout for a single precision floating point number.
--------------------------------------...
I'm not really sure how to figure this out.
I need to write a struct that will be part of a bigger program.
This particular one needs to be able describe the memory layout?
If anyone could supply code and maybe explain a bit I would be very grateful.
Three answers:
videobobkart
2009-02-18 23:27:21 UTC
In the other question like this one you said you knew the layout of a single-precision floating-point number, but just didn't know how to represent that layout as a C struct. Tell me that layout and I can tell you how to write a C struct definition that represents that layout. Yes I could go to Wikipedia and find the layout myself but then I'd be answering both halves of the question.
Questrade Coupon Code
2009-02-15 16:53:50 UTC
I think it is simply asking to create the code:



struct Single

{

float fMyFloatNumber;

};



Thats it. This definition "describes" the memory layout.
2016-11-06 11:04:41 UTC
feels like the subject concerns lie on your considerable(). You first use the reserved observe "struct" as, interestingly, a function call, then you relatively use the variable s devoid of defining it. desire that enables.


This content was originally posted on Y! Answers, a Q&A website that shut down in 2021.
Loading...