Computer Science  >  STUDY GUIDE  >  University of British Columbia - CPSC 110lab-11 solution cpsc 110. (All)

University of British Columbia - CPSC 110lab-11 solution cpsc 110.

Document Content and Description Below

;; Venue is (make-vnu String (listof Streetway)) ;; interp. a venue name and streetways leading from that venue (@htdd Streetway) (define-struct sw (nm dst)) ;; Streetway is (make-sw String Venue) ... ;; interp. (make-sw s v) is a streetway s that leads to the destination venue v. (define M0 (shared ([-AHB- (make-vnu "Anti-Hero 13 Boutique" (list))] [-RR- (make-vnu "Rocket Reprographics" (list (make-sw "Cordova Eastbound" -AHB-)))] [-VFS- (make-vnu "Vancouver Film School" (list (make-sw "Hastings Westbound" -WTFD-) (make-sw "Homer Northbound" -RR-)))] [-WTFD- (make-vnu "WOW Tasty Food Delivery" (list (make-sw "Hastings Eastbound" -VFS-)))]) (list -AHB- -RR- -VFS- -WTFD-))) ;; Online students: complete the following as your lab foundation. ;; On-ground students: complete the following as your pre-lab. ;; The incomplete data definition can represent venues and ;; streetways in Vancouver or anywhere else. Using the given example as ;; a guide, define an example of your own that includes AT LEAST the venues ;; and streetways in the block that spans from Richards to Hamilton and from ;; Dunsmuir to Hastings (there are 9 venues and 17 streetways in that block). ;; The provided examples are encapsulated, so they should not ;; interfere with your definition. DO NOT REUSE THE GIVEN EXAMPLE TO ;; DEFINE YOURS. ;; ;; Then complete the data definition by writing a template for the given data ;; definitions. DO NOT ADD ACCUMULATORS, simply produce the template ;; that corresponds to the type comments. You may encapsulate them ;; under the name fn-for-map, which takes a venue as its argument. (define (fn-for-map v0) (local [(define (fn-for-venue v) (... (vnu-nm v) (fn-for-losw (vnu-los v)))) (define (fn-for-losw losw) (cond [(empty? losw) (...)] [else (... (fn-for-sw (first losw)) (fn-for-losw (rest losw)))])) [Show More]

Last updated: 3 years ago

Preview 1 out of 4 pages

Buy Now

Instant download

We Accept:

Payment methods accepted on Scholarfriends (We Accept)
Preview image of University of British Columbia - CPSC 110lab-11 solution cpsc 110. document

Buy this document to get the full access instantly

Instant Download Access after purchase

Buy Now

Instant download

We Accept:

Payment methods accepted on Scholarfriends (We Accept)

Reviews( 0 )

$7.00

Buy Now

We Accept:

Payment methods accepted on Scholarfriends (We Accept)

Instant download

Can't find what you want? Try our AI powered Search

91
0

Document information


Connected school, study & course


About the document


Uploaded On

Apr 08, 2021

Number of pages

4

Written in

All

Seller


Profile illustration for Expert Tutor
Expert Tutor

Member since 4 years

58 Documents Sold

Reviews Received
6
2
0
0
3
Additional information

This document has been written for:

Uploaded

Apr 08, 2021

Downloads

 0

Views

 91

Document Keyword Tags

Recommended For You

Get more on STUDY GUIDE »

$7.00
What is Scholarfriends

Scholarfriends.com Online Platform by Browsegrades Inc. 651N South Broad St, Middletown DE. United States.

We are here to help

We're available through e-mail, Twitter, Facebook, and live chat.
 FAQ
 Questions? Leave a message!

Follow us on
 Twitter

Copyright © Scholarfriends · High quality services·