level 1
拉瓦CBYTX197
楼主
subroutine Q(N,A,K)
integer A(N/2)
A(1)=1
DO i=2,n/2
if(mod(n,i)==0)then
【?】
A(K)=I
end if
END DO
K=K+1
A(K)=N
end subroutine
integer,allocatable::A(:),B(:)
integer x,y
read*,x,y
allocate(A(X/2),B(Y/2))
call Q(X,A,K1)
call Q(Y,B,K2)
KK=0
do i=1,K1
do j=1,K2
if(A(I)==B(J))then
KK=KK+1
【?】
end if
end do
end do
print*,KK
end
2018年06月12日 09点06分
1
integer A(N/2)
A(1)=1
DO i=2,n/2
if(mod(n,i)==0)then
【?】
A(K)=I
end if
END DO
K=K+1
A(K)=N
end subroutine
integer,allocatable::A(:),B(:)
integer x,y
read*,x,y
allocate(A(X/2),B(Y/2))
call Q(X,A,K1)
call Q(Y,B,K2)
KK=0
do i=1,K1
do j=1,K2
if(A(I)==B(J))then
KK=KK+1
【?】
end if
end do
end do
print*,KK
end