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.
mình chuyển luôn nhé
a, (x*x+y)/(x*y)
b, 1/2 sin( sqrt(sqr(x)+sqr(y)))
chỗ này bạn làm dấu căn mình k hiểu mấy
c, sqrt(2*x)+sqrt(2*x)+sqrt(2*x)
hoặc là: 3*sqrt(2*x)
uses crt;
var n,a,b,q:integer;
begin
clrscr;
write('n='); readln(n);
for a:=1 to n do
for b:=a to n do
if trunc(sqrt(sqr(a)+sqr(b)))=sqrt(sqr(a)+sqr(b)) then writeln(a,' ',b);
readln;
end.
bài 1:
uses crt;
var i,t,x:integer;
begin
clrscr;
t:=0;
for i:=1 to 10 do
begin
x:=sqr(i);
t:=t+x;
end;
writeln('gia tri cua bieu thuc P=1^2+2^2+3^2+4^2+5^2+...+10^2 la: ',t);
readln;
end.
1.uses crt;
var n,gt:longint;
begin
clrscr;
repeat
write('nhap so n:');readln(n);
until n>0;
gt:=1;
while n>0 do
begin
gt:=gt*n;
n:=n-1;
end;
writeln('giai thua cua n la:',gt);
readln
end.
2. uses crt;
var a,b,c:real;
begin
clrscr;
write('nhap a=');readln(a);
write('nhap b=');readln(b);
write('nhap c=');readln(c);
if (a*a=b*b+c*c) or (b*=c*c+a*a) or (c*c=a*a+b*b) then writeln('khong phai la tam giac vuong');
readln
end.
const fi='xsum1.inp';
fo='xsum1.out';
var f1,f2:text;
a:array[1..20000]of integer;
i,n,j,x,dem,k,m,t:integer;
begin
assign(f1,fi); reset(f1);
assign(f2,fo); rewrite(f2);
readln(f1,n,x);
for i:=1 to n do
read(f1,a[i]);
dem:=0;
for i:=1 to n do
for j:=1 to n do
begin
for k:=1 to n do
if (i<j) and (j<k) then
begin
t:=0;
for m:=i to k do
t:=t+a[m];
if t=x then inc(dem);
end;
end;
for i:=1 to n do
if x=a[i] then inc(dem);
writeln(f2,dem);
close(f1);
close(f2);
end.
program COST;
var n,m,s,dem:int64;a:
array[1..1000000] of int64;
i,j:longint;
begin
readln(n,m);
for i := 1 to n do read(a[i]);
dem := 0;
for i := 1 to n do
begin
s := 0;
for j := i to n do
begin
s := s+a[j];
if s <= m then
begin
inc(dem);
continue;
end
else if a[j] > m then break;
end;
end;
write(dem);
end.
Program hotrotinhoc;
var x,n,i,j: integer;
t: longint;
function mu(k,m: integer): longint;
var s: longint;
l: integer;
begin
s:=1;
for l:=1 to m do
s:=s*k;
mu:=s;
end;
begin
t:=0;
write('X='); readln(x);
write('N='); readln(n);
for i:=1 to n do
t:=t+mu(x,i);
write(t);
readln
end.