The Daily CLAD

Community Browser
cancel
Showing results for 
Search instead for 
Did you mean: 

Re: Lots of white space in this mall

SercoSteveB
Active Participant

What is Boolean Array Out following execution of the VI?

 

NOTE:  32 is the ASCII representation of the Space character.

 

White Space.png

 

White Space Answers.png

Comments
nik35324
Member

D.

Read help before answering. Floating point numbers are rounded to the nearest integer.

MrStevenUND
Member

Unless my eyes deceive me, I think A and C are the same.

 

Ans: D.  Unlike we were taught in school, 32.5 rounds down to 32.

 

 

 

Matt-A.
Member

D.  Very interesting. 

Timsrice
Member

D

 

6 characters qualify as white space

(ASCII Code in the brackets)

 

(09) TAB       or \t      'horizontal' TAB

(10) LF         or \n     'Line feed' or 'new line'

(11) VT         or \0B   'Vertical' TAB (this one probably has no use)

(12) FF         or \f      'Form feed' or 'new page'

(13) CR        or \r      'Carriage return' 

(32) SPACE or \s      as explained in the question

 

Unix text files, lines end with \n

Mac text files, lines end with \r

Windows & DOS text files, lines end with \r\n

 

Timsrice
Member

Rounding

Goes to the nearest even integer (read about this here)

So 32.5 rounds to 32

and so would 31.5

 

This is sometimes known as 'Banker's rounding' and is used because there will be roughly as many rounding errors 'up' as 'down'.  

crossrulz
Knight of NI

D


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
CataM
NI Employee (retired)

d) LabVIEW needs to go back to school Smiley Very Happy

crossrulz
Knight of NI

In regards to the rounding, it is this way based on the IEEE standard (IEEE floating point rounding rules).  Though, sometimes I do wish there were a Round To Nearest Away From 0, Round Away From 0, and Round Toward 0 functions.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
SercoSteveB
Active Participant

Answer:  D.  Nice one all.

 

Answers A and C are indeed the same, I am pretty sure one of them was supposed to have the last element of the array set to TRUE as after all "White Space" must be white space?

RishiDivakar
Member

 Hi, Can anyone please explain how the numeric constants give output with whitespace function?

Certified LabVIEW Architect
System Test Architect
Electrical Engineering
JLR
crossrulz
Knight of NI

Look on the ASCII table.  32 = 0x20 = Space


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5