using System;
using System.Text; // Лучше всего для работы со строками использовать StringBuilder
namespace ConsoleApp3
{
class Program
{
static void Main(string[] args)
{
Console.Write("Введите 1-ю строку: ");
StringBuilder s = new StringBuilder(Console.ReadLine());
Console.Write("Введите 2-ю строку: ");
string s0 = Console.ReadLine();
s.Replace(s0, null);
Console.WriteLine("\n" + s);
Console.ReadKey();
}
}
}
Пример[Скриншот]
program prosto tak;
uses crt;
var
x, y, a, b, i, k:integer;
begin
readln(x, y);
readln(a,b);
k:=0;
k:=a-x;
if (b>y) or (b=y) then k:=k+1;
writeln(k);
readln;
end.
должно заработать