Басаргисидаса.
Убираем все буквы 'с' и гласные после них-и получается исходное слово
Вот программа с елкой:
Uses GraphABC;
Begin
SetWindowSize(600,400);
line(250,100, 300,50);
lineto(350,100);
lineto(250,100);
floodfill(300,70, clgreen);
line(220,200, 300,100);
lineto(380,200);
lineto(220,200);
floodfill(300,150, clgreen);
line(200,300, 300,200);
lineto(400,300);
lineto(200,300);
floodfill(300,250, clgreen);
rectangle(290, 300,310, 320);
floodfill(300,305, clbrown);
line(0, 300, 100, 350);
lineto(200, 320);
lineto(400, 320);
lineto(600, 370);
lineto(600,400);
lineto(0,400);
lineto(0,300);
<span>end. </span>
#include <stdio.h>
#include <stdlib.h>
int main()
{
int n, f=0;
scanf ("%d", &n);
int a[n];
srand (time(NULL));
for (int i = 0; i < n; i++ )
{
a[i] = rand() % 20 -10;
printf ("%4d ", a[i]);
}
printf("\n");
for (int i = 0; i < n; i++ )
if (a[i]==0) f++;
if (f>0) printf("YES");
else printf("NO");
return 0;
}
Пример:
10
<span> -1 -4 0 1 2 5 -7 -8 5 6
YES</span>
у меня почему то не открывается
begin
var n := ReadInteger('n =');
var a := ArrRandom(n, -99, 99);
a.Println;
var b := a.Where(p -> p > 0).Sorted.ToArray;
if b.Length > 0 then
begin
var j := 0;
for var i := 0 to a.High do
if a[i] > 0 then begin
a[i] := b[j];
j += 1
end
else
a[i] := 0
end;
a.Println
end.