Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

Welcome to the new platform of Programmer's Heaven! We apologize for the inconvenience caused, if you visited us from a broken link of the previous version. The main reason to move to a new platform is to provide more effective and collaborative experience to you all. Please feel free to experience the new platform and use its exciting features. Contact us for any issue that you need to get clarified. We are more than happy to help you.

How to read address using an Array

rodneybunkleyrodneybunkley Posts: 5Member
How do I read an address using an Array??
How do I read something like this:

425 LOS VERDES DR

using an array? Do I do a separate array for characters and one for integers?

Comments

  • _Atex__Atex_ Posts: 163Member
    : How do I read an address using an Array??
    : How do I read something like this:
    :
    : 425 LOS VERDES DR
    :
    : using an array? Do I do a separate array for characters and one for
    : integers?
    :

    You'll need a [b]record[/b] instead of an array to store different types of data in one "package", e.g.[code]type address=record
    house_number:word;
    street_name:string;
    end;[/code]Then use this record in an array to store multiple addresses[code]var a:array[1..20] of address;

    {...}

    a[1].house_number:=425;
    a[1].street_name:='LOS VERDES DR';[/code]
Sign In or Register to comment.