BLACK FRIDAY SALE – Unlock Up to 25% OFF on All Exam Prep! - Ends In 00:00:00 Coupon code: SAVE25
Welcome to Pass4Success

- Free Preparation Discussions

CompTIA FC0-U71 Exam - Topic 6 Question 2 Discussion

Posted by Queen on Jun 12, 2025 at 11:57 AM

Which of the following data types would be best for storing data representing a phone number?

Suggested Answer: A

A phone number is best stored as a string because it may include leading zeros, parentheses, dashes, or plus signs, which are not handled properly by numeric data types like integers or floats.

Other options:

Integer and float are numeric types unsuitable for formatted phone numbers,

Char holds only a single character.


Get Premium FC0-U71 Questions as Interactive Web-Based Practice Test or PDF Real Exam Format Detailed Explanations Instant Access Get Your Practice Test
30 comments · newest first
ON
Onita 11 months ago
Float is just wrong for this.
LA
Laura 11 months ago
Agreed, numbers can have leading zeros.
TI
Timothy 12 months ago
Wait, can you really use Char for that? Seems odd.
JE
Jeanice 12 months ago
Integer? That’s a bad choice!
NA
Nana 1 year ago
Definitely a String for phone numbers!
HE
Hector 1 year ago
I guess Char could work for a single digit, but it wouldn't make sense for a whole phone number, right?
JU
Jutta 1 year ago
I practiced a similar question, and I believe String is definitely the right choice because phone numbers aren't used for calculations.
SE
Selma 1 year ago
I'm not entirely sure, but I remember something about using integers for numeric data. Wouldn't that apply here?
TH
Thaddeus 1 year ago
I think a phone number should be stored as a String since it can have leading zeros and special characters like dashes.
PE
Pearline 1 year ago
I'm leaning towards Char for this one. Since phone numbers are just a sequence of digits, Char would be the most space-efficient data type, right? Though I guess you'd have to worry about formatting and validation.
DO
Dorathy 1 year ago
String is definitely the way to go here. Phone numbers can have all sorts of formatting, like area codes, country codes, and extensions, so a String data type would be the most flexible option.
CH
Chi 1 year ago
I'm a bit unsure about this one. I know phone numbers are typically numeric, so maybe an Integer would be better? But then again, some phone numbers start with a 0, which could cause issues with an Integer.
JE
Jeannetta 1 year ago
Hmm, this seems like a straightforward question. I think the best data type for storing a phone number would be a String, since phone numbers can contain non-numeric characters like parentheses and hyphens.
LA
Lawana 1 year ago
I disagree. B) Integer would be more efficient for storing phone numbers as it takes up less memory and allows for easier mathematical operations.
DA
Darrin 1 year ago
I think A) String is the best choice too. Phone numbers can have different lengths and special characters.
CH
Cheryl 1 year ago
Char? What is this, the stone age? String is the way to go, people.
IV
Ivette 1 year ago
↳ replying to Cheryl
I agree, using a string data type allows for flexibility and easy manipulation of phone number data.
PE
Peggy 1 year ago
↳ replying to Cheryl
String is definitely the best choice for storing phone numbers.
MI
Micheal 1 year ago
Float? Really? Who's gonna have a phone number with decimal places?
CA
Caprice 1 year ago
Integer, because phone numbers are just numbers, right? No need for all that string stuff.
AL
Alona 1 year ago
↳ replying to Caprice
Integer, because phone numbers are just numbers, right? No need for all that string stuff.
LA
Lanie 1 year ago
↳ replying to Caprice
D) Char
TA
Tabetha 1 year ago
↳ replying to Caprice
C) Float
LA
Lachelle 1 year ago
↳ replying to Caprice
B) Integer
EL
Elizabeth 1 year ago
↳ replying to Caprice
A) String
IR
Irving 1 year ago
String for sure, gotta fit all those digits in there!
EV
Evangelina 1 year ago
↳ replying to Irving
A) String is the way to go for phone numbers.
CA
Carmen 1 year ago
↳ replying to Irving
Definitely String, you need all those digits!
TH
Thurman 1 year ago
↳ replying to Irving
A) String
TO
Tora 1 year ago
A) String would be best for storing a phone number because it can hold a sequence of numbers and characters.
0/2000 characters

Save Cancel