From dc96fed3687dfff172c09266dd7b20d2b60db9bf Mon Sep 17 00:00:00 2001 From: Zhao Zuohong <1040110848@qq.com> Date: Wed, 4 Nov 2020 23:11:12 +0800 Subject: [PATCH] =?UTF-8?q?=E5=8F=91=E5=B8=83=E4=BA=86=E7=AC=AC=E5=9B=9B?= =?UTF-8?q?=E6=AC=A1=E4=BD=9C=E4=B8=9A?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- source/_posts/homework4.md | 41 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 source/_posts/homework4.md diff --git a/source/_posts/homework4.md b/source/_posts/homework4.md new file mode 100644 index 0000000..e4d733b --- /dev/null +++ b/source/_posts/homework4.md @@ -0,0 +1,41 @@ +--- +title: 第四次作业 +mathjax: true +date: 2020-11-04 23:10:54 +tags: +--- + + +# P137-3 + +输入两个正整数 $m$ 和 $n$ ,求其最大公约数和最小公倍数。 + +# P137-5 + +求 $S_{n} = a + aa + aaa + \cdots + \overbrace{aa \cdots a}^{n个a}$ 之值,其中 $a$ 是一个数字, $n$ 表示 $a$ 的位数, $n$ 由键盘输入。例如: + +$2 + 22 + 222 + 2222 + 22222$ (此时 $n = 5$ ) + +# P138-14 + +用牛顿迭代法求下面方程在 $1.5$ 附近的根: + +$$ +\begin{equation*} +2 x^{3} - 4 x^{2} + 3 x - 6 = 0 +\end{equation*} +$$ + +# P138-15 + +用二分法求下面方程在 $(-10, 10)$ 的根: + +$$ +\begin{equation*} +2 x^{3} - 4 x^{2} + 3 x - 6 = 0 +\end{equation*} +$$ + +# 选择排序 + +定义一个一维数组,用选择法给任意输入的十个整数排序。