From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-0.0 required=5.0 tests=BAYES_20 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,e4042699db4db63b,start X-Google-Attributes: gid103376,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news3.google.com!goblin2!goblin.stu.neva.ru!feed1.news.be.easynet.net!news.skynet.be!195.238.0.222.MISMATCH!newsspl501.isp.belgacom.be!tjb!not-for-mail Date: Thu, 12 Mar 2009 14:29:27 +0100 From: Olivier Scalbert User-Agent: Thunderbird 2.0.0.19 (X11/20090105) MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: Newbie question Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Message-ID: <49b90e2d$0$2847$ba620e4c@news.skynet.be> Organization: -= Belgacom Usenet Service =- NNTP-Posting-Host: b4a4f733.news.skynet.be X-Trace: 1236864557 news.skynet.be 2847 87.65.185.66:33205 X-Complaints-To: usenet-abuse@skynet.be Xref: g2news1.google.com comp.lang.ada:4070 Date: 2009-03-12T14:29:27+01:00 List-Id: Hello, I start learning Ada and I try to define types for a chess engine. I have create some "obvious" types: type Color_T is (White, Black); type PieceType_T is (Pawn, Knight, Bishop, Rook, Queen, King); type Piece_T is record Color: Color_T; PieceType: PieceType_T; end record; Now, I want to create an array of 64 squares representing the chess board. A square should contain nothing or a Piece_T I have tried: type Board_T is array(1..64) of Piece_T; But I can not have an empty square ! What is the best way of doing that ? Thanks, Olivier