• Congratulations to the Class of 2024 on your results!
    Let us know how you went here
    Got a question about your uni preferences? Ask us here

Wildcard Substitution... (1 Viewer)

rach_1

New Member
Joined
Aug 11, 2005
Messages
25
Gender
Female
HSC
2005
I understand what this symbol substitution is and why its used, but i have a question where i dont know how they got the answer.

It is from a database of names. Which result will Sm*h display?

a) Smith
b) Smythe
c) Smithers
d) Sompson

Now i thought that the search could return either a, b and c because they all have Smh in name, but the answer is B.

How did they come to that conclusion?
 

...

^___^
Joined
May 21, 2003
Messages
7,723
Location
somewhere inside E6A
Gender
Male
HSC
1998
* is used for any number of characters

so in this case it can only be Smith

cos Sm*th means there is an "infinite" amount of characters between m and t; from the option only Smith matches this query, as other solutions have characters outside the query condition
 

rach_1

New Member
Joined
Aug 11, 2005
Messages
25
Gender
Female
HSC
2005
Yeh i thought it was smith also but the answer is B - Smythe...I dont understand it
 

skyrockets1530

Member++
Joined
Sep 10, 2004
Messages
184
Location
Sydney
Gender
Male
HSC
2005
... said:
* is used for any number of characters

so in this case it can only be Smith

cos Sm*th means there is an "infinite" amount of characters between m and t; from the option only Smith matches this query, as other solutions have characters outside the query condition
yea, thats correct, the answer is wrong. the query sm*h would not return smythe- not even in ms access, it just wouldnt work
 

Lwaxana

Betazed Ambassador
Joined
Oct 16, 2002
Messages
430
Location
in a galaxy far far away
Gender
Female
HSC
N/A
the questions wasnt so much wrong as badly constructed

it was (from memory) Find the result of Sm*th?

the ? was taken by some students to be the end of the actual question

as opposed to representing a wildcard for a Single character

thus making
Smythe

the "right" answer
 

Chocobo687

New Member
Joined
Oct 14, 2005
Messages
16
Gender
Male
HSC
2005
Sounds like that was a bit of a screwy question.
My understanding:
* - Any number of undefined characters
? - One character per question mark.
 

Tommy_69

Old Member
Joined
Sep 24, 2004
Messages
492
Location
Sydney
Gender
Male
HSC
2005
rach_1 said:
I understand what this symbol substitution is and why its used, but i have a question where i dont know how they got the answer.

It is from a database of names. Which result will Sm*h display?

a) Smith
b) Smythe
c) Smithers
d) Sompson

Now i thought that the search could return either a, b and c because they all have Smh in name, but the answer is B.

How did they come to that conclusion?
You wrote the question wrong - CSSA 2004 Question 3 is

"Now Jody uses the following search on surnames. Which result will Sm*h? display?"

ok firstly "*" gives you more than one unknown character and "?" gives you one character. So therefore the answer is B

Sm*h? = Sm(y)(t)h(e)
 
Joined
Oct 24, 2004
Messages
666
Location
Penrith area..
HSC
N/A
I know this has been answered about 1ooooo times in this thread, but anyway - with wildcards, when you have an astrisk (*) it means that any number of characters can replace it - and when you are given a question mark (?) it stands for one character;

Which result will Sm*h display?
a) Smith
b) Smythe
c) Smithers
d) Sompson

For this ^ scenario..
Sm*h means that there can be any number of characters in place of the astrisk - therefore the answer is A - Smith. However, if the question had been:
Which result will Sm?h display?
None of the answers would be correct - as a question mark signifies only 1 character..

sooo..
in conclusion

? = ONLY ONE CHARACTER
* = ONE OR MORE CHARACTERS

.. sorry about that caps-ing in the last part (i'm just trying to emphasise my point)
=)

good luck people!

=[edit]= .. sorry dude - the question was like screwin me over
.. read the 2 posts before mine =P
but

* = any number of letters/numbers
? = only one
^ that's the key point to remember!
 
Last edited by a moderator:

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Top