如何求解问题 pdf解

如何编程求解 100 以内的质数?
按投票排序
133 个回答
print prime under 100 Brainf**k impl
&&++[&+++++[&+++++&-]&-]&&.&&++++[&+++++
+++&-]&.&+.&.&&&+++++[&+++++[&++++&-]&-]
&&------&+++++&[&&&&[-]+++[-&+&+&&]&&[-&
&+&&]&&+&&&&&&+[[-]&[-&+&+&&]&&[-&&+&&]&
&[-]&[-&+&+&&]&&[-&&+&&]&&&&[-&&&-&+&[&-
]&[-&&[-&+&+&&]&&[-&&+&&]&]&&&&&]&&[-&-&
+&&]&&[-&&+&&]+&[&-]&[-&&[-]&]&&&&&&[-&+
&+&&]&&[-&&+&&]&&[-]&++[-&+&+&&]&&[-&&+&
&]&[-&&&-&&&]&&&]&&&&&&[&&&&&&&[-&+&+&&]
&&[-&&+&&]&[-]++++++++++&[-]++++++++++&&
&[-&&&-&+&[&-]&[-&&[-&+&+&&]&&[-&&+&&]&&
&+&[-]-&&&]&&&+&&&&&&&&]&&&&&&&[++++++++
++++++++++++++++++++++++++++++++++++++++
.[-]]&++++++++++++++++++++++++++++++++++
++++++++++++++.[-]&&&&&&&&&&&.&&&&&&&&&-
]&&&&&&&++&--]
Brainf**k大法好上面的程序也许不太好懂,我们来展开一下:// 输出一些特例
&&++[&+++++[&+++++&-]&-]&&. // 输出'2'
&&++++[&++++++++&-]&. // 输出空格
&+. // 输出'3'
&. // 输出空格
// 开始循环计算
& &&+++++[&+++++[&++++&-]&-]&&------ // 循环次数:94
&+++++ // 从5开始逐个判断
& [ // 循环直到循环次数为0
&&&& [-] +++ // 初始化除数为3
[-&+&+&&]&&[-&&+&&] // 复制一份除数用于计算
&& + // 标记是否是质数的flag
&&&&&& + // 进入试除循环
[ // 循环条件见对应的方括号之前
& [-&+&+&&]&&[-&&+&&] // 复制一份被除数用于计算
&& [-] & [-&+&+&&]&&[-&&+&&] // 复制一份除数(OAO前面那个其实好像没必要
// 开始计算余数
&&&& [ // 循环条件:被除数不为0
&&& - // 被除数和除数各减1
// 看看下面这行是如何实现分支的?
&+ & [&-] & [ - // 除数为0
&& [-&+&+&&]&&[-&&+&&] // 就再复制一份除数来
&& [-&-&+&&] && [-&&+&&]
+& [ &- ] & [ - // 被除数和除数同时为0,说明整除
&& [-] // 清除质数标记
[-&+&+&&]&&[-&&+&&] // 被除数
& ++ // 除数加2
[-&+&+&&]&&[-&&+&&] // 除数
[-&&&-&&&] // 被除数大于除数,循环继续;否则结束循环
// 算完了,打印
[ // 是质数
[-&+&+&&]&&[-&&+&&] // 复制一份用来计算显示
// 下面是和之前计算类似的除10操作
&[-]++++++++++
&[-]++++++++++
&+ & [ &- ] & [ - // 减一次10
&& [-&+&+&&]&&[-&&+&&]
&&& + // 十位数加1
& [-]- // 清空个位数,这里减的1会以循环外面补上
&&& + // 个位数+1
// 有十位数则输出
&&&&&&& [++++++++++++++++++++++++++++++++++++++++++++++++ . [-]]
// 输出个位数
& ++++++++++++++++++++++++++++++++++++++++++++++++ . [-]
// 输出空格
&&&&&&&&&&&.&&&&&&&&&
- // 清除质数flag
&&&&&&& ++ // 被除数加2
& -- // 循环次数减2
Wireworld 机械图,可以逐个在七段数码管里显示素数。这玩意 Golly 里有对应的 rle,可以直接打开运行(记得调高速度到 10000x)。来源图中已包含。对应的「汇编语言」是:对应的「汇编语言」是:Reg
Disassembly
MOV R0 ,R30 set display to 2
MOV R54,R31 initialise mask register for sign bit test
MOV R32,R33 set candidate prime p=3
MOV R60,R34 the trial divisor q is stored in the adder as its
negative: here it is initialised to -1, i.e. q=1
MOV R61,R35 other summand=-2
MOV R60,R61 next trial divisor q=q+2
MOV R61,R32 move p to adder summand input a, which holds remainder
MOV R57,R36 for the first time round the loop, set the target
for the branch if subtraction gives zero to 20: this
detects the case p==q, which means we have done all
the trial divisors and p is prime
MOV R55,R37 if subtraction result non-zero, target is 13
MOV R56,R61 test a-q
MOV R63,R56 branch to selected target
MOV R61,R61 a-=q
MOV R61,R61 a-=q (continuing here if subtraction result not zero)
MOV R53,R61 move a-q to and-not register to check sign
MOV R57,R38 target is 9 if a-q positive (round subtraction loop
MOV R55,R39 else target is 5 (q does not divide p, so try next q)
MOV R56,R54 test a-q AND 0x8000
MOV R63,R56 branch to selected target
MOV R57,R40 reset target for other branch to 21 (a zero result
from the subtraction now indicates q properly
divides p and so p is composite)
MOV R0 ,R32 p is prime: write it to the display
MOV R61,R32 move p to adder
MOV R60,R30 other summand=2
MOV R63,R41 goto 4 to try new p
MOV R32,R61 p+=2
0002 constant 2
7 constant mask for sign bit testing
0005 current candidate p
0003 constant 3
constant -1
constant -2
20 branch target: trial divisor q equal to candidate p,
and hence prime found
13 branch target: trial divisor q less than candidate p
9 branch target: more subtractions to do
5 branch target: next trial divisor q
21 branch target: subtraction gave zero, so p composite
4 branch target: next candidate p
constant -3
各个寄存器读写时的行为是:
我尝试用一行C++11代码模仿
的 Python式实现:copy_if(range(2, 101), ostream_iterator&int&(cout, " "), [](int x){ return none_of(range(2, x), [x](int y) { return x % y == 0; }); });
这样比较容易理解:copy_if(
range(2, 101),
// 数列 { 2, 3, .. 100 } 中的整数
ostream_iterator&int&(cout, " "), // 至cout(每个输出后加入空格)
[](int x) {
// 仅当对于每个整数x
return none_of(
// 没有一个
range(2, x),
// y in { 2, ..., x - 1 }
[x](int y) {
return x % y == 0;
// y 为 x 的因子
-----为了实现这个函数式实现,C++11不提供range()的功能,需要自行实现一个。完整的程序是这样的:#include &algorithm&
#include &iostream&
#include &iterator&
using namespace std;
template &typename T&
class range_type {
class range_iterator {
typedef T value_type;
typedef T* pointer;
typedef T& reference;
typedef ptrdiff_t difference_type;
typedef forward_iterator_tag iterator_category;
range_iterator(T v) : v_(v) {}
T operator*() const { return v_; }
range_iterator operator++() { ++v_; return *this; }
range_iterator operator++(int) { range_iterator copy(*this); ++v_; return copy; }
bool operator==(const range_iterator &other) const { return v_ == other.v_; }
bool operator!=(const range_iterator &other) const { return v_ != other.v_; }
range_type(T lower, T upper) : lower_(lower), upper_(upper) {}
range_iterator begin() const { return range_iterator(lower_); }
range_iterator end() const { return range_iterator(upper_); }
T lower_, upper_;
template &typename T&
range_type&T& range(T lower, T upper) { return range_type&T&(lower, upper); }
template &typename Container, typename UnaryPredicate&
bool none_of(const Container& c, UnaryPredicate pred) { return none_of(c.begin(), c.end(), pred); }
template &typename Container, typename DestIterator, typename UnaryPredicate&
void copy_if(const Container& c, DestIterator d, UnaryPredicate pred) { copy_if(c.begin(), c.end(), d, pred); }
int main() {
copy_if(range(2, 101), ostream_iterator&int&(cout, " "), [](int x){ return none_of(range(2, x), [x](int y) { return x % y == 0; }); });
另外,因为C++ algorithm标头档的函数都使用 begin, end 作为参数,为了把程序写成一行,我加入了使用container作为参数的none_of()和copy_if()。相信没有学生会把这段代码当功课交吧。-----更新:不少评论说了各种「优化」方法。包括把内循环的范围从降至,或者更好的。另外也可以只测试之前的质数是否因子。我作了一个简单的测试:void test(int t, std::vector&int&& p, int n, function&bool(int)& isPrime) {
p.clear();
clock_t start = clock();
copy_if(range(2, n + 1), back_inserter(p), isPrime);
clock_t end = clock();
cout && t && ". " && p.size() && " " && (end - start) * 1000.0 / CLOCKS_PER_SEC && "ms" &&
int main() {
std::vector&int&
p.reserve(10000);
const int n = 100000;
test(1, p, n, [](int x) { return none_of(range(2, x), [x](int y) { return x % y == 0; }); });
test(2, p, n, [](int x) { return none_of(range(2, x), [x](int y) { return y * 2 &= x && x % y == 0; }); });
test(3, p, n, [](int x) { return none_of(range(2, x / 2 + 1), [x](int y) { return x % y == 0; }); });
test(4, p, n, [](int x) { return none_of(range(2, x), [x](int y) { return y * y &= x && x % y == 0; }); });
test(5, p, n, [](int x) { return none_of(range(2, x), [x](int y) { return y &= (int)sqrt(x) && x % y == 0; }); });
test(6, p, n, [](int x) { return none_of(range(2, (int)sqrt(x) + 1), [x](int y) { return x % y == 0; }); });
test(7, p, n, [&p](int x) { return none_of(p, [x](int y) { return x % y == 0; }); });
test(8, p, n, [&p](int x) { return none_of(p, [x](int y) { return y * y &= x && x % y == 0; }); });
test(9, p, n, [&p](int x) { return none_of(p, [x](int y) { return y &= (int)sqrt(x) && x % y == 0; }); });
test(10, p, n, [&p](int x) {
for (auto y : p) {
if (y & (int)sqrt(x))
else if (x % y == 0)
//copy(p, ostream_iterator&int&(cout, " "));
为了测试性能,我把n调至100000,并避免输出字符串的开销,只把结果写在vector里。运行结果:1. ms
6. 9592 11ms
8. 9592 65ms
9. 9592 33ms
10. 9592 4ms
如果能减少范围,直接改动上界(测试3、6)是较好的。虽然测试5减少了调用sqrt(),但因为仍然需要迭代整个范围,会比测试6要慢得多。对于使用之前结果中的质数,测试7比测试6(简单的开方优化)要慢。但在这情况下,我们不能改变上界(不知道现时已存的质数哪个大于x的开方),测试8和9的结果仍然比测试6要慢。最后,唯有放弃使用none_of(),才能避免迭代整个范围,达到这些测试中最优的测试10。
0到100而已,你们至于么?口算不就行了?vector&int& prime_0_100()
return vector&int&{2,3}; //010 and 011
WordBasic Function Prim(n)
Dim i, j, x, p
For i = 2 To n
For i = 2 To n
If a(i) = 1 Then
While j &= n
FileNew .NewTemplate = 0, .Template = "NORMAL"
Insert "All prime numbers smaller than"
Insert Str$(n)
InsertPara
For i = 2 To n
If a(i) = 1 Then
Insert Str$(i)
Insert ","
End Function
Begin Dialog UserDialog 214, 100
Text 25, 10, 125, 13, "Largest Number:"
TextBox 24, 32, 160, 18, .SNum
OKButton 75, 66, 88, 21
End Dialog
Dim sinput As UserDialog
Dialog sinput
n = Int(Val(sinput.snum))
'MsgBox Str$(n)
If n & 0 Then
a = Prim(n)
MsgBox("Wrong Input!")
运行环境和运行结果
既然这题已经被玩坏了。。。我也要玩。。。你们那些语言都退下吧!看我大莎士比亚语言!Prime Number Computation in Copenhagen.
Romeo, a young man of Verona.
Juliet, a young woman.
Hamlet, a temporary variable from Denmark.
The Ghost, a limiting factor (and by a remarkable coincidence also
Hamlet's father).
Act I: Interview with the other side.
Scene I: At the last hour before dawn.
[Enter the Ghost and Juliet]
The Ghost:
You pretty little warm thing! Thou art as prompt as the difference
between the square of thyself and your golden hair. Speak your mind.
Listen to your heart!
[Exit the Ghost]
[Enter Romeo]
Thou art as sweet as a sunny summer's day!
Act II: Determining divisibility.
Scene I: A private conversation.
Art thou more cunning than the Ghost?
If so, let us proceed to scene V.
[Exit Romeo]
[Enter Hamlet]
You are as villainous as the square root of Romeo!
You are as lovely as a red rose.
Scene II: Questions and the consequences thereof.
Am I better than you?
If so, let us proceed to scene III.
Is the remainder of the quotient between Romeo and me as good as
If so, let us proceed to scene IV.
Thou art as bold as the sum of thyself and a roman.
Let us return to scene II.
Scene III: Romeo must die!
[Exit Hamlet]
[Enter Romeo]
Open your heart.
[Exit Juliet]
[Enter Hamlet]
Thou art as rotten as the difference between nothing and the sum of a
snotty stinking half-witted hog and a small toad!
Speak your mind!
[Exit Romeo]
[Enter Juliet]
Scene IV: One small dog at a time.
[Exit Hamlet]
[Enter Romeo]
Thou art as handsome as the sum of thyself and my chihuahua!
Let us return to scene I.
Scene V: Fin.
好吧我承认我也不知道什么意思。。。。官网抄的。。。嗯哼。。。
找了好久没看到有C#的!!!请告诉我C#不是一个人!
static void Main(string[] args)
for (int i = 2; i &= 100; i++)
bool b = true;
for (int j = 2; j & i; j++)
if (i % j == 0)
b = false;
Console.WriteLine("{0}是质数", i);
Console.ReadKey();
怎么能少了SQL 脚本? --准备原材料
CREATE TABLE primes
number INT
DECLARE @i INT
SET @i = 2 --1不是质数,我们舍弃它
WHILE @i & 100
INSERT INTO primes
---下面的查询返回100以内的质数
SELECT A.*
NOT EXISTS (SELECT number
B.number & A.number
AND A.number % B.number = 0)
--你也可以这样
--打印出100以内的质数
DECLARE @len INT
DECLARE @i INT
DECLARE @j INT
DECLARE @bl BIT
SET @len = 100
SET @i = 2
SET @j = 2
IF EXISTS (SELECT Object_id (N'TEMPDB..##temp1'))
DROP TABLE ##temp1
SELECT NULL AS '质数'
WHILE @i & @len
SET @bl = 0
WHILE @j & @i
IF @i % @j = 0
SET @bl = 1
IF @bl = 0
INSERT INTO ##temp1
SET @j = 2
SET @i += 1
DELETE ##temp1
质数 IS NULL
这是一段收录在维基百科里用dc计算器求质数的程序,采用逆波兰式计算表达式,计算过程是对栈的手动维护。这个程序会一直循环下去。很简洁,只有一行:echo '2p3p[dl!d2+s!%0=@l!l^!&#]s#[s/0ds^]s@[p]s&[ddvs^3s!l#x0&&2+l.x]ds.x'|dc
a:array [1..100]
for i:=1 to 100 do a[i]:=i;
a[1]:=0;i:=2;
while i&=100 do
while k&=100 do
{————上面将所有a[i]的倍数清0}
while a[i]=0 do i:=i+1;
{————查找接下来的第一个非0数}
for i:=1 to 100 do if a[i]&&0 then write(a[i],' ');
-----------------------------------------------------------------------------------
data segment
D1 DW 200 DUP(0) ;定义数组
code segment
main proc far
assume cs:code,ds:data
MOV AX,DATA
MOV SI,OFFSET D1
CMP DX,100 ;100以内的数
SHR AX,1 ;/2
;2,3,....
;余数为0,非素数
LOOP LOOP1
MOV [SI],DX ;保存素数
这个时候当然要祭出正则表达式求素数的版本。(1 x ++$_) =~ /^1?$|^(11+?)\1+$/ || print "$_\n" while $_ & 100
既然有人问原理,那就祭出m67的博文吧:
c/c++语言实现怎么能少得了预处理器的,搜索了一下发现已经有各种古怪的了,我就用boost preprocessor写一个通用一些的:#include &stdio.h&#include &boost/preprocessor/arithmetic.hpp&
#include &boost/preprocessor/comparison.hpp&
#include &boost/preprocessor/control.hpp&
#include &boost/preprocessor/logical.hpp&
#include &boost/preprocessor/expand.hpp&
#define PRIME_CHECK(d, tuple) \
BOOST_PP_IF(BOOST_PP_LESS(BOOST_PP_TUPLE_ELEM(4, 1, tuple), BOOST_PP_TUPLE_ELEM(4, 2, tuple)), PRIME_CHECK_MOD, 0 BOOST_PP_TUPLE_EAT(4)) tuple
#define PRIME_CHECK_MOD(p, d, n, tuple) \
BOOST_PP_NOT_EQUAL(BOOST_PP_MOD(p, BOOST_PP_TUPLE_ELEM(n, d, tuple)), 0)
#define PRIME_CHECK_ITERATE(d, tuple) \
(BOOST_PP_TUPLE_ELEM(4, 0, tuple), BOOST_PP_INC(BOOST_PP_TUPLE_ELEM(4, 1, tuple)), BOOST_PP_TUPLE_ELEM(4, 2, tuple), BOOST_PP_TUPLE_ELEM(4, 3, tuple))
#define PRIME_CHECK_AFTER(tuple) \
BOOST_PP_IF(BOOST_PP_LESS(BOOST_PP_TUPLE_ELEM(4, 1, tuple), BOOST_PP_TUPLE_ELEM(4, 2, tuple)), PRIME_APPEND_NONE, PRIME_APPEND) tuple
#define PRIME_APPEND(p, d, n, tuple) \
BOOST_PP_INC(n), (BOOST_PP_TUPLE_REM(n) tuple, p)
#define PRIME_APPEND_NONE(p, d, n, tuple) \
#define PRIME_WHILE_PRED(d, tuple) \
BOOST_PP_LESS_EQUAL(BOOST_PP_TUPLE_ELEM(4, 0, tuple), BOOST_PP_TUPLE_ELEM(4, 1, tuple))
#define PRIME_WHILE_OP(d, tuple) \
(BOOST_PP_INC(BOOST_PP_TUPLE_ELEM(4, 0, tuple)) \
, BOOST_PP_TUPLE_ELEM(4, 1, tuple) \
, PRIME_CHECK_AFTER(BOOST_PP_WHILE(PRIME_CHECK, PRIME_CHECK_ITERATE, (BOOST_PP_TUPLE_ELEM(4, 0, tuple), 0, BOOST_PP_TUPLE_ELEM(4, 2, tuple), BOOST_PP_TUPLE_ELEM(4, 3, tuple)))))
#define PRIME_TUPLE_TO_ARRAY(tuple) \
{ BOOST_PP_EXPAND(BOOST_PP_TUPLE_REM(BOOST_PP_TUPLE_ELEM(4, 2, tuple)) BOOST_PP_TUPLE_ELEM(4, 3, tuple)) }
#define PRIME_ARRAY(n) \
PRIME_TUPLE_TO_ARRAY(BOOST_PP_WHILE(PRIME_WHILE_PRED, PRIME_WHILE_OP, (3, n, 1, (2))))
int primes[] = PRIME_ARRAY(100);
int main()
for (i = 0; i & sizeof(primes) / sizeof(int) - 1; ++i) {
printf("%d, ", primes[i]);
printf("%d\n", primes[i]);
请注意,PRIME_ARRAY(100)的编译时间可能很长并且大量占用内存,如果不想爆机的话,可以选取一个较小的数做起。
我也来个Python版本:&&& f = lambda x: [1 for v in xrange(1, int(math.sqrt(x)) + 1) if x % v == 0]
&&& print [x for x in xrange(1, 100) if len(f(x)) == 1]
提供一个 Ruby 版供参考print (2..100).select {|n| (2..(n + 1) / 2).all? {|d| n % d &0}}
输出[2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67,
71, 73, 79, 83, 89, 97]
补充刚才无聊,比较了一下
的 C++ 11 版本,
的 Python 版本, 和上面 Ruby 版本的速度 (求 2..10000 内的质数,用命令 time 测试耗费时间),测试环境 Mid 2013 MacBook Air 13 inch 1.3GHZ Core i5 CPU on Yosemite 10.10. 编译器解释器都是 Xcode 6.1 或 Yosemite 自带的。 下面是结果:C++ 11
(clang-600.0.54
(Python 2.7.6)
(Ruby 2.1.1p76)
C++ 11 在这个任务上比 Ruby 快 10 倍,Ruby 比 Python 快 20 倍。 印象中 Python 比 Ruby
略快的。再补充:
评论中提出一种更好的 Python 方案print [x for x in range(2,10001) if all(x%y for y in range(2,(x+2)/2))]
这种方案运行时间为 590ms ,经过
进一步提示,把 range 替换成 xrange 后速度提升为 369ms , 基本上和 Ruby 版本持平。 我估计
版本的效率问题主要是冗余的列表和容器操作造成的。初步结论: 1. 在算法等价的情况下,C++ 实现大约比 Python 和 Ruby 实现快一个数量级。2. 脚本语言中的非优化实现,很容易进一步造成一个数量级以上的性能差距。
我去…………能见到的语言基本都齐活儿了…………貌似没人说Matlab??primes(100)
看,一行多简洁~
Python 也试试?In [1]: print filter( lambda x: len(filter(lambda y: x%y == 0,range(2,x-1))) == 0 , range(2,101) )[2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, 73, 79, 83, 89, 97]
Matlab大法好!cleart=1;for i=1:100for j=1:iif (round(i/j)==(i/j)&j~=1&j~=i)breakend endif j==is(t)=i;t=t+1;%disp(['素数:',num2str(i)])endenddisp(['素数:',num2str(s)])
file format elf32-i386
Disassembly of section .text:
3: 83 e4 f0
$0xfffffff0,%esp
6: 83 ec 20
$0x20,%esp
9: c7 44 24 18 02 00 00
$0x2,0x18(%esp)
51 &main+0x51&
13: 8b 44 24 18
0x18(%esp),%eax
17: 8b 04 85 00 00 00 00
0x0(,%eax,4),%eax
4c &main+0x4c&
22: 8b 44 24 18
0x18(%esp),%eax
28: 89 44 24 1c
%eax,0x1c(%esp)
45 &main+0x45&
2e: 8b 44 24 1c
0x1c(%esp),%eax
32: c7 04 85 00 00 00 00
$0x1,0x0(,%eax,4)
39: 01 00 00 00
3d: 8b 44 24 18
0x18(%esp),%eax
41: 01 44 24 1c
%eax,0x1c(%esp)
45: 83 7c 24 1c 63
$0x63,0x1c(%esp)
2e &main+0x2e&
4c: 83 44 24 18 01
$0x1,0x18(%esp)
51: 83 7c 24 18 63
$0x63,0x18(%esp)
13 &main+0x13&
58: c7 44 24 18 02 00 00
$0x2,0x18(%esp)
8a &main+0x8a&
62: 8b 44 24 18
0x18(%esp),%eax
66: 8b 04 85 00 00 00 00
0x0(,%eax,4),%eax
85 &main+0x85&
71: 8b 44 24 18
0x18(%esp),%eax
75: 89 44 24 04
%eax,0x4(%esp)
79: c7 04 24 00 00 00 00
$0x0,(%esp)
80: e8 fc ff ff ff
81 &main+0x81&
85: 83 44 24 18 01
$0x1,0x18(%esp)
8a: 83 7c 24 18 63
$0x63,0x18(%esp)
62 &main+0x62&
输出2 3 5 7 11 13 17 19 23 29 31 37 41 43 47 53 59 61 67 71 73 79 83 89 97
php 大法好!echo "2 3 5 7 11 13 17 19 23 29 31 37 41 43 47 53 59 61 67 71 73 79 83 89 97";
Lisp没人来吗,我来吧(define (prime? n)
(define(prime-iter i)
(let ((m (sqrt n)))
(cond ((& i m) true)
((= (remainder n i) 0) false)
(else (prime-iter (+ i 1))))))
(prime-iter 2))
(define (primes n)
(define (get-primes arr n)
(cond ((& n 2) arr)
((prime? n) (get-primes (cons n arr) (- n 1)))
(else (get-primes arr (- n 1)))))
(get-primes null n))
(primes 100)如何求解问题pdf(书籍) - 下载频道
- CSDN.NET
&&&&如何求解问题pdf(书籍)
如何求解问题pdf(书籍)
如何求解问题,遇到问题,怎样求解,困扰大家,希望本书能够帮一些忙。
若举报审核通过,可奖励20下载分
被举报人:
yingshuai16
举报的资源分:
请选择类型
资源无法下载
资源无法使用
标题与实际内容不符
含有危害国家安全内容
含有反动色情等内容
含广告内容
版权问题,侵犯个人或公司的版权
*详细原因:
您可能还需要
开发技术下载排行新华调查:“一床难求”与“空置率48%”矛盾并存的背后--养老机构“冰火两重天”如何求解?
  新华网北京7月27日电(记者黄小希、陈诺)截至2014年底,我国60岁以上人口超过2亿,约7个人中就有一位老人。养老既是社会之难,更是个人之忧——
  仅从养老机构来说,一方面公众对养老机构存有“入住难”“一床难求”的印象,另一方面却是养老机构全国平均空置率达48%的现实,“冰火两重天”折射出当前我国养老机构面临的结构性“失衡”问题。
  “48%空置率”细解:村镇敬老院入住不足,城市养老院一床难求
  中国老龄科学研究中心近期发布的《中国养老机构发展研究报告》指出,“十二五”时期,我国养老机构取得了突破性进展,但目前养老机构空置率较高,全国平均达到48%。
  中国老龄科学研究中心主任吴玉韶接受新华社记者采访时指出,我国养老机构的空置现象主要出现在农村,而不是在城市,48%的平均值中有相当一部分来自农村敬老院。
  “在我国养老机构中,农村敬老院占很大比例,主要是为农村五保老人设置的,但五保老人分布分散,机构建设不可能完全按照实际人头数进行床位设置,结果就出现了较高的空置率,有的敬老院空置率甚至在50%以上。”吴玉韶说。
  记者在安徽走访时发现,阜阳市颍上县有农村敬老院70余家,入住率仅为30%左右,总入住人数在5000人左右。针对空置率高的问题,颍上县民政局党组成员徐伟介绍,民政部门正着手将农村敬老院的收住对象由五保户放宽到留守老人等群体。
  一些基层民办养老机构也出现类似的情形。颍上县的协和老年公寓开办于2013年8月,上下三层近60个房间,床位数达140个,承担了相当一部分五保老人的照顾任务。然而记者在现场看到,除了一二层有老人入住外,整个三层空无一人,公寓负责人孙以鹏告诉记者,开办两年来“生意”一直不红火,“现在这里也仅入住了65位老人,和员工数差不多”。
  与此形成鲜明对比的是,城市养老机构的床位利用率总体较高,一些公办养老机构甚至出现“一床难求”的现象。家住安徽省芜湖市镜湖区的孙翠兰老人近两年换了四家民办养老院,“也想住公办,但就是没有空床位”,她告诉记者,当地公办养老院数量不多且早已人满为患。
  不过,值得注意的是,地处城市郊区的养老机构,入住率也相对较低。养老机构郊区化,使得老年人脱离了原有生活圈,不仅子女不方便探望,还割裂了老年人与其他年龄层人群的交往。孙翠兰现在居住的养老院就位于市郊,距离市区至少需要1个半小时车程,为此儿女们不得不把一周一次的探望缩减为一月一次,“以前出门就是超市、商场,如今去一趟市区像是过年,时间长了也闷得慌”。
  养老机构既要增数量,更要调结构
  近年来,跟随我国老龄人口不断增加的步伐,养老机构数量规模呈现持续发展态势。数据显示,截至2014年底,全国共有各类养老服务床位550余万张,每千名老年人拥有养老床位数在26张左右。民政部部长李立国在2015年全国民政工作会议上表示,要继续加快发展养老服务业,确保今年实现每千名老年人拥有养老床位达到30张的目标。
  然而,与人民群众日益增长的养老需求相比,养老机构的发展还有很长的路。专家指出,我国老龄化社会的现实要求发展更多的养老机构,但从长远来看,养老机构主要服务对象应当是失能半失能老人,他们才是养老机构应予以满足的“刚需”。同时,我国养老机构的供给格局亟待改变,应重点发展满足中等收入老年人经济水平的中档养老机构,将养老机构的结构从“哑铃型”调整为更为合理的“橄榄形”。
  记者了解到,城市养老机构虽然总体入住率好,但其中的“高低两端”发人深思。低端的养老机构设施简陋,空间狭小,居住拥挤,服务内容单一。孙翠兰透露,自己住过的养老院大多是旧房子改建的,护理人员也基本是周边请来的中年妇女,普遍缺乏护理技能,“有的光会打扫屋子、端饭端菜,我们真有个头疼脑热,她们也摸不准情况”。而有的高端养老机构则专门服务经济状况好的老年群体,地理位置优越,装饰豪华高档,硬件设施完备,服务内容丰富。许多子女和老人既不愿意选择前一类养老机构,又无力承担后一类的高额收费。
  吴玉韶表示,这种“哑铃型”结构,主要出现在民办养老机构中。“我所了解的一家高端民办养老机构,每间房每月收费1万多元,开办一年多了,300多张床位只有10%左右的入住率。”
  《中国养老机构发展研究报告》认为,未来应在新增养老机构中大力发展城区中小型和小微型养老机构,就近就便解决中低收入、失能半失能老人的养老问题。政府投资建设的养老机构应当以养护型养老机构为主,满足失能半失能老人的护理需求。现有的农村敬老院也要实现转型发展,增加康复护理服务功能,不仅服务五保老人,还要对农村的失能半失能老人开放,向农村养老护理服务中心转型。
  吴玉韶表示,随着经济社会发展和老年人对养老服务专业化需求的提高,未来养老机构小型化、专业化、品牌化、连锁化的趋势将更加明显。
  养老院应明确服务对象
  芜湖市一民办养老院负责人告诉记者,如今无论是公办还是民办,接收老年人实际上只根据身体状况作价格上的区分,没有太多限制,“只要有钱,有空床位,住公住私随你定”,这直接导致公办养老资源被过度追捧,该负责人透露,有的公办吸引不少异地老人“慕名而来”,有的甚至还需“托关系”。
  业内人士指出,对于在地理位置、服务、收费等方面存在优势的公办养老机构,导致“一床难求”的原因之一是对收住的老年人没有明确的身体状况、经济状况的界定,除了收住三无老人、五保老人等政策托底对象外,还收住部分社会老年人,使得一些低龄、健康、经济条件较好的社会老年人早早“排队”。
  目前,一些地方已经开始对公办养老机构职能定位不明确问题进行改革。以北京为例,今年印发的《关于深化公办养老机构管理体制改革的意见》要求公办养老机构明确接收对象,作出了公办养老机构接收对象为具有本市户籍的基本养老服务保障对象和其他失能或高龄的老年人等规定。
  专家建议,作为“保基本、兜底线”的公办养老机构,应当提供救助性和保障性的基本养老服务,服务对象应当是三无、五保、高龄、失能、失独等存在特殊困难的老年群体。姓“公”的公办养老机构要明确入住对象,回归“保基本、兜底线”本位。
[责任编辑:

我要回帖

更多关于 如何求解多项式方程 的文章

 

随机推荐