Results 1 to 3 of 3

Thread: 3 Scheme

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Registered User vladata's Avatar
    Join Date: Dec:2008
    Location:
    Posts: 72

    3 Scheme

    , Scheme, "- " 3 . Scheme . :

    1- S:
    a) ,
    )

    2- m n. : n(n + m)(n + 2m)(n + 3m)...(n + mm)
    - Let ,

    3- S, (a, b].

  2. #2
    Registered User Neverine's Avatar
    Join Date: Sep:2004
    Location: /
    Posts: 721
    Code:
    (define (zad1a list)
      (if (null? list) list
         (if (< (car list) 0) (cdr list)
             (cons (car list) (zad1a (cdr list))))))
    
    (define (zad1b list)
      (if (null? list) list
          (if (< (car list) 0) ( (cdr list))
              (cons (car list) (zad1b (cdr list))))))
    
    (define (zad2 n m)
      (define (iter i m)
        (if (<= i m) (* (+ n (* i m)) (iter (+ i 1) m))
            1))
      (iter 0 m))
    
    (define (zad3 list a b)
      (define (count list br)
        (if(null? list) br
           (if( and (<= (car list) b) (> (car list) a))
              (count (cdr list) (+ br 1))
              (count (cdr list) br))))
      (count list 0))
    , .
    P5Q Deluxe | E8500 | EK-Supreme + MCP655 + MCR220 + Feser Tube | 2*2GB A-Data 800 | GB HD3850 256MB | WD6401AALS | Lite-on 20A1S | PC P&C Silencer 610W | Antec P182 | Belinea 102035
    F2 F3

  3. #3
    Registered User vladata's Avatar
    Join Date: Dec:2008
    Location:
    Posts: 72
    ,

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

Copyright © 1999-2011 . .
iskamPC.com | mobility.BG | Bloody's Techblog | | 3D Vision Blog |