Run Code
|
API
|
Code Wall
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
d
//Rextester.Program.Main is the entry point for your code. Don't change it. //Microsoft (R) Visual C# Compiler version 2.9.0.63208 (958f2354) using System; using System.Collections.Generic; using System.Linq; using System.Text.RegularExpressions; namespace Rextester { public class Program { public static void Main(string[] args) { int lessThenZero = 0; int moreThenZero = 0; for(double x = -2.2d; x <= 2.2d; x+=0.2d) { x = Math.Round(x, 2); double y = (Math.Pow(x, 2) * Math.Sin(Math.PI) * x) / Math.Sqrt(4 * Math.Cos(x)); if (y < 0) lessThenZero++; if (y > 0) moreThenZero++; Console.WriteLine($"x: {x} y: {y}"); } Console.WriteLine("\n*не число - значит что подкоренное выражение меньше нуля"); Console.WriteLine("----------"); Console.WriteLine($"у больше нуля: {moreThenZero}\ny меньше нуля: {lessThenZero}"); Console.ReadLine(); } } }
run
|
edit
|
history
|
help
0
GGT
Strings in C# with some properties examples
base interior 0.1
Vxksnanndjsnajajnaannannnananannaannanaannananna
concrete class with inheritance
newDivQ DONE - adding UniqueShuffle
Overriding
enigma 2
Kare Çizimi
Linear search vs. Binary search