Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8494591
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T23:20:34+00:00 2026-06-10T23:20:34+00:00

In scheme I have to use random to define a procedure that accepts no

  • 0

In scheme I have to use random to define a procedure that accepts no arguments and returns an integer in the range 1 to 10, inclusive and i cant use if. im lost =(

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-10T23:20:35+00:00Added an answer on June 10, 2026 at 11:20 pm

    If your Scheme provides a random function, you want either

    (define (1-10-rand)
        (+ 1 (random 10)))
    

    or

    (define (1-10-rand)
        (floor (* 10 (random))))
    

    depending on whether you have (random n) --> integer in [0, n-1]) or (random) -> float in [0,1]

    Be advised that this isn’t standards-compliant. For absolute portability, write your own RNG.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have two apps that use custom URL schemes to switch between each other.
I have the following schema, which I use to ensure that a person's PhoneNumber
In SQL we have a scheme script that creates tables which has some logic
I'm currently designing a DB scheme. I have to use hsqldb. - Normally I
I have the following data scheme that I want to turn into an application.
I currently use a color scheme based on which directory that I'm working in.
I have an app that uses standard id integer autoincrement values. I also have
Say I have a scheme that derives a key from N different inputs. Each
Using scheme I have the need to use the following function. (All args are
I use a non-default Windows colour scheme on most of my machines, and have

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.