K
Khách

Hãy nhập câu hỏi của bạn vào đây, nếu là tài khoản VIP, bạn sẽ được ưu tiên trả lời.

19 tháng 5 2022

uses crt;

const fi='output.txt';

var f1:text;

a:array[1..100]of integer;

i,n:integer;

begin

clrscr;

readln(n);

for i:=1 to n do readln(a[i]);

assign(f1,fi); rewrite(f1);

for i:=1 to n do 

 if i mod 2=1 then write(f1,a[i]:4);

writeln(f1);

for i:=1 to n do 

if a[i] mod 2<>0 then write(f1,a[i]:4);

close(f1);

readln;

end.

21 tháng 8 2023

Câu sau đúng:

c) Trong tất cả các hệ CSDL hễ có sự cố không truy cập được một máy chủ CSDL thì toàn bộ hệ thống CSDI đó ngừng hoạt động.

d) Một hệ CSDL phân tán đắt hơn so với một hệ CSDL, tập trung vì nó phức tạp hơn nhiều.

23 tháng 4 2021

uses crt;

const fi='kiemtra.txt';

var f1:text;

a:array[1..100]of integer;

min,n,i:integer;

{----------------chuong-trinh-con-------------------}

function nn(x,y:integer):integer;

begin

if x<y then nn:=x

else nn:=y;

end;

{-----------------chuong-trinh-chinh-----------------}

begin

clrscr;

write('nhap n='); readln(n);

for i:=1 to n do 

  begin

write('A[',i,']='); readln(a[i]);

end;

min:=nn(a[1],a[2]);

for i:=3 to n do 

  if min>a[i] then min:=a[i];

writeln(min);

readln;

end.

23 tháng 4 2021

Mình xin sửa lại một chút:

uses crt;

const fi='kiemtra.txt';

var f1:text;

a:array[1..100]of integer;

min,n,i:integer;

{----------------chuong-trinh-con-------------------}

function nn(x,y:integer):integer;

begin

if x<y then nn:=x

else nn:=y;

end;

{-----------------chuong-trinh-chinh-----------------}

begin

clrscr;

assign(f1,fi); reset(f1);

readln(f1,n);

for i:=1 to n do 

  read(f1,a[i]);

min:=nn(a[1],a[2]);

for i:=3 to n do 

  if min>a[i] then min:=a[i];

writeln(min);

readln;

end.

15 tháng 4 2022

uses crt;

const fo='output.txt';

var f1:text;

st:string;

d,i:integer;

begin

clrscr;

readln(st);

assign(f1,fi); rewrite(f1);

d:=length(st);

for i:=d downto 1 do 

  write(f1,st[i]);

close(f1);

readln;

end.

1 tháng 5 2020

Program hotrotinhoc_hoc24;

const fi='D:\BT3.txt';

var f: text;

i,n,d: integer;

a: array[1..32000] of integer;

procedure ip;

begin

assign(f,fi);

reset(f);

readln(f,n);

for i:=1 to n do

read(f,a[i]);

d:=0;

for i:=1 to n do if a[i] mod 2=0 then d:=d+1;

end;

begin

write(d);

readln

end.

1 tháng 5 2020

uses crt;

const fi='bt3.txt'';

var f1:text;

n,i,dem:integer;

a:array[1..100]of integer;

begin

clrscr;

assign(f1,fi); reset(f1);

n:=0;

while eoln(f1) do

begin

inc(n);

read(f1,a[n]);

end;

dem:=0;

for i:=1 to n do

if a[i] mod 2=0 then inc(dem);

writeln('So so chan trong day la: ',dem);

close(f1);

readln;

end.

5 tháng 5 2020

const fi='dulieu.txt';

fo='tong.doc';

var f1,f2:text;

n,i,s:integer;

begin

assign(f1,fi); reset(f1);

assign(f2,fo); rewrite(f2);

readln(f1,n);

s:=0;

for i:=1 to n do

s:=s+i;

writeln(f2,s);

close(f1);

close(f2);

end.

8 tháng 6 2020

Program HOC24;

var n,i: integer;

a: array[1..32000] of integer;

procedure out;

begin

assign(f,'KQ.txt');

rewrite(f);

for i:=1 to n do write(f,a[i],' ');

close(f);

end;

begin

readln(n);

for i:=1 to n do read(a[i]);

out;

readln

end.

22 tháng 8 2023

Lưu dữ liệu dưới dạng 1 phần mềm hệ thống quản trị mà ai cũng có thể dễ dàng khai thác.

15 tháng 5 2020

Bài 3:

Program HOC24;

const fi='Nhapvao.txt';

var f: text;

begin

assign(f,fi);

reset(f);

close(f);

end.

15 tháng 5 2020

Bài 2:

Program HOC24;

const fo='CaDao.txt';

var f: text;

begin

assign(f,fo);

rewrite(f);

writeln(f,'Cong cha nhu nui thai son');

writeln(f,'Nghia me nhu nuoc trong nguon chay ra.');

writeln(f,'Mot long tho me kinh cha');

write(f,'Cho tron chu hieu moi la dao con');

close(f);

end.

2 tháng 3 2020

const fi='songuyen.txt';
fo='sole.txt';
var f1,f2:text;
n,i,t:integer;
a:array[1..100]of integer;
begin
assign(f1,fi); reset(f1);
assign(f2,fo); rewrite(f2);
n:=0;
while not eoln(f1) do
begin
inc(n);
read(f1,a[n]);
end;
t:=0;
for i:=1 to n do
if a[i] mod 2=1 then t:=t+a[i];
writeln(f2,t);
close(f1);
close(f2);
end.