public static void UzipFiles(string zipPath, string directoryOutPath, string filterExtension, bool copyAll =false){
var outDir = new DirectoryInfo(directoryOutPath);
if (!outDir.Exists)
outDir.Create();
var archFile = new FileInfo(zipPath);
if(!archFile.Exists)
return;
using (var f = File.Open(archFile.FullName, FileMode.Open)){
System.IO.Compression.ZipArchive arch = new ZipArchive(f, ZipArchiveMode.Read);
int i = 1;
foreach (var entry in arch.Entries.Where(e=> e.Name.ToLower().EndsWith(filterExtension.ToLower()))){
using (Stream sr = entry.Open()){
var ext = "";
try{
ext = new FileInfo(entry.Name).Extension;
}
catch (Exception){}
string outFileName = archFile.Name +(copyAll?i++.ToString():"")+ ext;
using (Stream sw = File.Create(outDir.FullName + "\\" + outFileName)){
while (true){
int data = sr.ReadByte();
if(data == -1)
break;
sw.WriteByte((byte) data);
}
}
}
if(!copyAll)
break;
}
}
}
UzipFiles(@"D:\myarch.zip", @"D:\outFolder",".eps",true); // Последний параметр true если выводить все найденные файлы, false если выводить только первый
let dateStart = new Date("2021-05-11 14:00:00").getTime();//Время начала
let numberStart = 100;//Число начала
let numberNow = Math.floor(numberStart + (Date.now()-dateStart)/1000/60);//Текущее значение числа
denominator = D * E * Math.Sin(F);
if (denominator != 0) {
gamma = (A + B * Math.Cos(C)) / (D + E * Math.Sin(F));