# rem和mod的區別

λ posted @ 2011年12月06日 18:27 in Mixture with tags lisp tutorial , 6930 阅读

# 細說rem＆mod（remainder＆modulo）

a ÷ b ＝ q … r

r ＝ a - q × b

## rem：使商向「內」取整

7 ÷ 3 ≈ 2.3

7 rem 3 ＝ 2 … 1

7 rem -3 ＝ -2 … 1

-7 rem 3 ＝ -2 … -1

-7 rem -3 ＝ 2 … -1

## mod：使商向「下」取整

7 ÷ 3 ≈ 2.3

7 mod 3 ＝ 2 … 1

7 mod -3 ＝ -3 … -2

-7 mod 3 ＝ -3 … 2

-7 mod -3 ＝ 2 … -1

OK，解說完畢。

## 其它資料

Creative Commons 保持署名-相同方式分享 2.5

Rrandom 说:
Dec 07, 2011 10:18:11 PM

racket里

> (remainder 1 3)
1
> (modulo 1 -3)
-2
> (remainder 1 -3)
1

remainder叫做取余.modulo叫做取模...

λ 说:
Dec 07, 2011 11:12:21 PM

-_-;感覺都一個意思，「模」好像是mo的擬聲。Racket竟然會用這麼完整的名稱啊……嗯，從結果看來，是同一標準的。

HDFC CIBIL score 说:
Aug 06, 2022 10:42:58 PM

Before we show you how you can check CIBIL score, first know that TransUnion CIBIL is an organization and an entity gathers all the consumer’s loan, credit, payment and money related transaction, and this gives a general behavior example and statics allowing to generate a score for each customer also calls as CIBIL score. In simple words, every individual based on their payment choices, credit decisions and money pertains may rank and given CIBIL score points which range up to 900 points. In the sense, if the customer receives anything above 750 – 900, <a href="https://25penny.com/cibil-score-login-check-report-free-paid/">HDFC CIBIL score</a> then they have high credit affinity. With this the banks and loan facilities may happy to lend credit to them. But in case if the CIBIL score for you is anywhere less than 750 or even worse then there are high chances that you will reject any loans, EMI, or credit requests. Because loan facilities and banks would consider your CIBIL Score as a baseline for approving those requests.

NCERT Sanskrit Sampl 说:
Sep 19, 2022 01:24:53 AM

The Sanskrit Language is one of the important languages and those 2nd Standard students of English Medium, Hindi Medium and Urdu Medium crossed it as their Second or Third Language. The Sanskrit language helps students to about the Indian culture and history of our country etc. So students who chose the Sanskrit language as their optional language can download NCERT Sanskrit Sample Paper 2023 Class 2. NCERT Sanskrit Sample Paper Class 2 Learning the Sanskrit language should begin from the foundation of Education to enable students to understand the language without any difficulties. To know the examination question pattern and scheme of the exam everyone can download NCERT Sanskrit Sample Paper 2023 Class 2 for all formats of exams conducted in Term 1, and Term 2.

Previous Paper 2024 说:
Feb 11, 2023 05:56:39 PM

Previous Paper 2024 Every one of the students are right now sitting tight for the test Model Paper to be Download, so need to reveal to you that as per the data got from the sources as of late, Previous Paper 2024 The board will deliver its Question Paper, realizing that it will be made accessible to you. Board of Secondary Education is otherwise called The Educational board leads secondary school and transitional board tests each year.

Elmer Deserres 说:
Apr 23, 2023 03:27:26 PM
jnanabhumiap.in 说:
Apr 25, 2023 02:32:16 PM

We provide you the finest of web content on each and every topics possible with help of editorial and content team.Jnanabhumi AP is a startup by passionate webmasters and bloggers who have passion to provide engaging content which is accurate, interesting and worthy to read. We are mope like a web community where you can jnanabhumiap.in find different information’s, resources, topics on day to day incidents or news.

Haryana 10th Class 说:
Aug 15, 2023 03:28:35 PM

seo service london 说:
Jan 16, 2024 10:57:58 PM

I just thought it may be an idea to post incase anyone else was having problems researching but I am a little unsure if I am allowed to put names and addresses on here

(输入验证码)
or Ctrl+Enter

280705