[Year 12 SofDev] Records and Arrays
Laurie Savage
savage.john.l at edumail.vic.gov.au
Thu Aug 19 09:06:31 EST 2010
I hope they'll adjust something that once was correct and maybe useful and
universal but is no longer. Steven Bird's earlier post attempted a
distinction but all he really illustrated (at least to this little black
duck) was that an array could be used to store a record. He did not
illustrate the necessary existence of a record as a an entity separate and
distinct from an array.
Laurie
From: sofdev-bounces at edulists.com.au [mailto:sofdev-bounces at edulists.com.au]
On Behalf Of Margaret Iaquinto
Sent: Thursday, 19 August 2010 8:55 AM
To: List', 'Year 12 Software Development Teachers' Mailing
Subject: Re: [Year 12 SofDev] Records and Arrays
How is this issue dealt with by the textbook writers for SD 2011?
Maggie
Margaret Iaquinto
Information Technology Coordinator
St Leonard's College
Brighton Campus
t (+61 3) 9909 9300
x 529
www.stleonards.vicedu.au <http://www.stleonards.vic.edu.au/>
Alternate email: maggie at iaquinto.net
>>> Laurie Savage <savage.john.l at edumail.vic.gov.au> 19/08/2010 8:43 AM >>>
Hmm, messy but I don't see any other way. So we teach the kids that this is
a "fact" or definition which does not apply to half of the languages being
used. Maybe we should be teaching them to prepare COBOL programs on punched
cards too.
Laurie
-----Original Message-----
From: sofdev-bounces at edulists.com.au [mailto:sofdev-bounces at edulists.com.au]
On Behalf Of Guy Flaherty
Sent: Thursday, 19 August 2010 8:41 AM
To: 'Year 12 Software Development Teachers' Mailing List'
Subject: Re: [Year 12 SofDev] Records and Arrays
After a quick bit of research, the following approved languages do not
follow the 'definition' of an array as stated on page 161 of the Fitzpatrick
& Keane text:
Objective C
Python
Perl
Ruby
PHP
Visual Fox Pro
The other six language do. According to the definitions, the above languages
do not have an 'array' type but are indeed following the definition for a
'record'. Despite the fact that for each of these languages the structures
are described and explained as 'arrays' in their documentation and not
referred to as 'record' types.
It would seem that Adrian's point of these definitions being used in the
study design is important, and must be considered a requirement of the
course. Equally, if you teach one of the languages above, your students are
not going to understand this well without specific help, in my opinion, as
this will not be their experience in practice.
The simple answer is that any language type that allows for multiple items
to be referred to as part of a single variable, when the items are required
to be of the same type you have an 'array' and when the items are allowed to
be of differing types you have a 'record'. According to the study design but
purely language dependent in real life.
Guy Flaherty
Xavier College
>>> "Adrian Janson" <janson.adrian.a at edumail.vic.gov.au> 18/08/10 05:58 PM
>>>
Hi Guy and all,
The definition of array and record are as you stated and I would have
thought that this was a common thing to all languages - but I am not
familiar with PHP at all - and was surprised to see that you could mix data
types in an array! It is important to remember that it is in the study
design (and the next one to) and so is fair game for the examiners (even
though as you said - it would be possibly a controversial topic given the
way PHP treats arrays and records....)
Cheers,
Adrian
Adrian Janson B.Sc, Dip.Ed, M.Ed
Director of ICT
Melbourne High School, Forrest Hill, South Yarra, Victoria 3141 Australia.
Phone: 03 9826 0711 International: +61 3 9826 0711
Fax: 03 9826 8767 International: +61 3 9826 8767
E-mail: janson.adrian.a at edumail.vic.gov.au
Website: <http://www.mhs.vic.edu.au/> http://www.mhs.vic.edu.au
Blog: <http://jansona.edublogs.org/> http://jansona.edublogs.org
-----Original Message-----
From: sofdev-bounces at edulists.comau [mailto:sofdev-bounces at edulists.com.au]
On Behalf Of Guy Flaherty
Sent: Wednesday, 18 August 2010 2:58 PM
To: sofdev at edulistscom.au
Subject: Re: [Year 12 SofDev] Records and Arrays
Laurie,
I initially thought exactly as you stated when I looked at the reference in
the book. So I did a quick search and in languages like c and pascal arrays
must be of the same data type and records(pascal)/struct(c) can have
different data types for items, as explained in the text.
Being a python using person myself, I am not used to this, as arrays can
have any type of data in them, and there really isn't a 'record' type in
python that I am aware of. I think php is similar.
It would seem that this kind of structure is language dependent, and so not
the best for an exam question, in my opinion.
Guy Flaherty
Xavier College
>>> "Laurie Savage" <savage.john.l at edumail.vic.gov.au> 18/08/10 01:57 PM >>>
I have a problem. In Fitzpatrick and Keane p. 161 (and in the 2007 exam)
arrays and records are primarily differentiated by data type. So the text
says: "An array is an indexed collection of elements of the same type of
data"; "A ... record represents a group of different data elements".
But, in PHP, this works:
<?php
$pizzaToppings = array('onion', 'tomato', 'cheese', 'anchovies', 'ham',
'pepperoni', 1.6, 200);
echo "<h1>We like $pizzaToppings[5] PIZZA!</h1>";
$num = $pizzaToppings[6] * $pizzaToppings[7];
echo $num;
?>
i.e. the array is storing data of different types and not storing the
numeric data as a string. What am I missing here? I've done a search, but
these are the only references I've seen that define this as the main
difference. I've been labouring under the delusion that an array lives in
volatile memory and disappears once the application halts or reinitialises
and a record is written to disk. I know from the web that I'm not alone
here.
Laurie Savage
Pascoe Vale Girls College
Important - This email and any attachments may be confidential. If received
in error, please contact us and delete all copies. Before opening or using
attachments check them for viruses and defects. Regardless of any loss,
damage or consequence, whether caused by the negligence of the sender or
not, resulting directly or indirectly from the use of any attached files our
liability is limited to resupplying any affected attachments. Any
representations or opinions expressed are those of the individual sender,
and not necessarily those of the Department of Education and Early Childhood
Development.
Scanned by Sonar.
Date: 2010-08-18 14:05:08.466
From: sofdev-bounces at edulists.com.au
To: g.flaherty at xavier.vic.edu.au
Profile: Default_In
Mail id: challenge-2104307658s34-0
"This email and any files transmitted with it are confidential and intended
solely for the use of the individual or entity to whom they are addressed.
If you have received this email in error please notify the Network Manager
at Xavier College. Please note that any views or opinions presented in this
email are solely those of the author and do not necessarily represent those
of Xavier College. Whilst every attempt has been made to ensure material in
this email message is free from computer viruses or other defects, the
attached files are provided, and may only be used, on the basis that the
user assumes all responsibility for the use of the material transmitted."
_______________________________________________
http://www.edulists.com.au - FAQ, Subscribe, Unsubscribe
IT Software Development Mailing List kindly supported by
http://www.vcaa.vic.edu.au - Victorian Curriculum and Assessment Authority
and
http://www.vcaa.vic.edu.au/vce/studies/infotech/softwaredevel3-4.html
http://www.vitta.org.au - VITTA Victorian Information Technology Teachers
Association Inc
Important - This email and any attachments may be confidential. If received
in error, please contact us and delete all copies. Before opening or using
attachments check them for viruses and defects. Regardless of any loss,
damage or consequence, whether caused by the negligence of the sender or
not, resulting directly or indirectly from the use of any attached files our
liability is limited to resupplying any affected attachments. Any
representations or opinions expressed are those of the individual sender,
and not necessarily those of the Department of Education and Early Childhood
Development.
Scanned by Sonar.
Date: 2010-08-18 18:10:22993
From: sofdev-bounces at edulists.com.au
To: g.flaherty at xaviervic.edu.au
Profile: Default_In
Mail id: challenge-2119009392sy3-0
"This email and any files transmitted with it are confidential and intended
solely for the use of the individual or entity to whom they are addressed.
If you have received this email in error please notify the Network Manager
at Xavier College. Please note that any views or opinions presented in this
email are solely those of the author and do not necessarily represent those
of Xavier College. Whilst every attempt has been made to ensure material in
this email message is free from computer viruses or other defects, the
attached files are provided, and may only be used, on the basis that the
user assumes all responsibility for the use of the material transmitted."
_______________________________________________
http://www.edulists.com.au - FAQ, Subscribe, Unsubscribe
IT Software Development Mailing List kindly supported by
http://www.vcaa.vic.edu.au - Victorian Curriculum and Assessment Authority
and
http://www.vcaa.vic.edu.au/vce/studies/infotech/softwaredevel3-4.html
http://www.vitta.org.au - VITTA Victorian Information Technology Teachers
Association Inc
Important - This email and any attachments may be confidential. If received
in error, please contact us and delete all copies. Before opening or using
attachments check them for viruses and defects. Regardless of any loss,
damage or consequence, whether caused by the negligence of the sender or
not, resulting directly or indirectly from the use of any attached files our
liability is limited to resupplying any affected attachments. Any
representations or opinions expressed are those of the individual sender,
and not necessarily those of the Department of Education and Early Childhood
Development.
_______________________________________________
http://www.edulists.com.au - FAQ, Subscribe, Unsubscribe
IT Software Development Mailing List kindly supported by
http://www.vcaa.vic.edu.au - Victorian Curriculum and Assessment Authority
and
http://www.vcaa.vic.edu.au/vce/studies/infotech/softwaredevel3-4.html
http://www.vitta.org.au - VITTA Victorian Information Technology Teachers
Association Inc
CAUTION - This message may contain privileged and confidential information
intended only for the use of the addressee named above. If you are not the
intended recipient of this message you are hereby notified that any use,
dissemination, distribution or reproduction of this message is prohibited.
If you have received this message in error please notify St Leonard's
College immediately. Any views expressed in this message are those of the
individual sender and may not necessarily reflect the views of St Leonard's
College.
Important - This email and any attachments may be confidential. If received in error, please contact us and delete all copies. Before opening or using attachments check them for viruses and defects. Regardless of any loss, damage or consequence, whether caused by the negligence of the sender or not, resulting directly or indirectly from the use of any attached files our liability is limited to resupplying any affected attachments. Any representations or opinions expressed are those of the individual sender, and not necessarily those of the Department of Education and Early Childhood Development.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.edulists.com.au/pipermail/sofdev/attachments/20100819/39ce8694/attachment-0001.html
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: image/png
Size: 9886 bytes
Desc: not available
Url : http://www.edulists.com.au/pipermail/sofdev/attachments/20100819/39ce8694/attachment-0001.png
More information about the sofdev
mailing list