当前位置: 首页>>代码示例>>C#>>正文


C# Student.IsOlderThan方法代码示例

本文整理汇总了C#中Student.IsOlderThan方法的典型用法代码示例。如果您正苦于以下问题:C# Student.IsOlderThan方法的具体用法?C# Student.IsOlderThan怎么用?C# Student.IsOlderThan使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Student的用法示例。


在下文中一共展示了Student.IsOlderThan方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: Main

        public static void Main()
        {
            Console.WriteLine(Geometry.CalcTriangleArea(3, 4, 5));

            Console.WriteLine(TextOperations.GetNumberAsWord(5));

            Console.WriteLine(Algebra.FindMax(5, -1, 3, 2, 14, 2, 3));

            ConsolePrinter.PrintFloatWithPrecision(1.3);
            ConsolePrinter.PrintNumberAsPercent(0.75);
            ConsolePrinter.PrinNumbertWithOffset(2.30, 8);

            Console.WriteLine(Geometry.CalculateDistance(3, -1, 3, 2.5));
            bool horizontal;
            bool vertical;
            horizontal = Geometry.PointHasSameDirection(3, 3);
            vertical = Geometry.PointHasSameDirection(-1, 2.5);
            Console.WriteLine("Horizontal? " + horizontal);
            Console.WriteLine("Vertical? " + vertical);

            Student peter = new Student() { FirstName = "Peter", LastName = "Ivanov" };
            peter.ExtraInfo = "From Sofia";
            peter.DateOfBirth = DateTime.Parse("03/17/1992");

            Student stella = new Student() { FirstName = "Stella", LastName = "Markova" };
            stella.ExtraInfo = "From Vidin, gamer, high results";
            stella.DateOfBirth = DateTime.Parse("11/03/1993");

            Console.WriteLine("{0} is older than {1} -> {2}", peter.FirstName, stella.FirstName, peter.IsOlderThan(stella));
        }
开发者ID:ilkodzhambazov,项目名称:Telerik-Academy,代码行数:30,代码来源:DemoProgram.cs

示例2: Main

        static void Main()
        {
            var trianlgle = new Triangle(3, 4, 5);
            Console.WriteLine(trianlgle.CalcTriangleArea(new HeronsFormulaArea()));

            Console.WriteLine(ConvertNumberToString(5));

            Console.WriteLine(FindMaxNumber(5, -1, 3, 2, 14, 2, 3));

            PrintInNumericFormat(1.3, "fixed-point");
            PrintInNumericFormat(0.75, "percentage");
            PrintInNumericFormat(2.30, "leftIndented");

            bool horizontal, vertical;
            Console.WriteLine(CalcPointDistance(3, -1, 3, 2.5));
            Console.WriteLine("Horizontal? " + CheckIfHorizontal(3, -1, 3, 2.5, out horizontal));
            Console.WriteLine("Vertical? " + CheckIfVertical(3, -1, 3, 2.5, out vertical));

            Student peter = new Student("Peter", "Ivanov", "From Sofia, born at 17.03.1992");
            
            Student stella = new Student("Stella", "Markova", "From Vidin, gamer, high results, born at 03.11.1993");
            
            Console.WriteLine("{0} older than {1} -> {2}",
                peter.FirstName, stella.FirstName, peter.IsOlderThan(stella));
        }
开发者ID:PlamenaMiteva,项目名称:Quality-Programming-Code,代码行数:25,代码来源:Methods.cs

示例3: Main

    public static void Main()
    {
        Console.WriteLine(Methods.CalcTriangleArea(3, 4, 5));

        Console.WriteLine(Methods.DigitToText(5));

        Console.WriteLine(Methods.FindMax(5, -1, 3, 2, 14, 2, 3));

        Console.WriteLine(Methods.FormatAsFloat(1.3));
        Console.WriteLine(Methods.FormatAsPercent(0.75));
        Console.WriteLine(Methods.FormatWithPadding(2.30, 8));

        Console.WriteLine(Methods.CalcDistance(3, -1, 3, 2.5));
        Console.WriteLine("Horizontal? " + Methods.IsHorizontal(3, -1, 3, 2.5));
        Console.WriteLine("Vertical? " + Methods.IsVertical(3, -1, 3, 2.5));

        var peter = new Student("Peter", "Ivanov", new DateTime(1992, 03, 17));
        peter.Town = "Sofia";

        var stella = new Student("Stella", "Markova", new DateTime(1993, 11, 03));
        stella.Town = "Vidin";
        stella.OtherInfo = "gamer, high results";

        Console.WriteLine("{0} older than {1} -> {2}", peter.FirstName, stella.FirstName, peter.IsOlderThan(stella));
    }
开发者ID:MarKamenov,项目名称:TelerikAcademy,代码行数:25,代码来源:MethodsTest.cs

示例4: Main

    static void Main()
    {
        Student peter = new Student() { FirstName = "Peter", LastName = "Ivanov" };
        peter.OtherInfo = "From Sofia, born at 17.03.1992";
        peter.BirthDate = new DateTime(1992, 03, 17);

        Student stella = new Student() { FirstName = "Stella", LastName = "Markova" };
        stella.OtherInfo = "From Vidin, gamer, high results, born at 03.11.1993";
        stella.BirthDate = new DateTime(1993, 11, 03);

        Console.WriteLine("{0} older than {1} -> {2}",
            peter.FirstName, stella.FirstName, peter.IsOlderThan(stella));
    }
开发者ID:TAanonymos,项目名称:TAanonymous,代码行数:13,代码来源:Student.cs

示例5: Main

    static void Main()
    {
        Console.WriteLine(Geometry.CalcTriangleArea(3, 4, 5));

        Console.WriteLine(Arithmetics.NumberToDigit(5));
        Console.WriteLine(Arithmetics.FindMax(5, -1, 3, 2, 14, 2, 3));

        Arithmetics.PrintAsFloatingPointNumber(1.3);
        Arithmetics.PrintAsPercentage(0.75);
        Arithmetics.PrintAsAlingNumber(2.30);

        Console.WriteLine(Geometry.CalcDistance(3, -1, 3, 2.5));
        Console.WriteLine("Horizontal? " + Geometry.CheckIsHorizontal(3, 3));
        Console.WriteLine("Vertical? " + Geometry.CheckIsVertical(-1, 2.5));

        Student peter = new Student("Peter", "Ivanov", "From Sofia, born at 17.03.1992");
        Student stella = new Student("Stella", "Markova", "From Vidin, gamer, high results, born at 03.11.1993");
        Console.WriteLine("{0} older than {1} -> {2}",
            peter.FirstName, stella.FirstName, peter.IsOlderThan(stella));
    }
开发者ID:vasilkrvasilev,项目名称:QualityCode,代码行数:20,代码来源:HighQualityMethods.cs

示例6: Main

        public static void Main()
        {
            Console.WriteLine(GeometryUtilities.CalcTriangleArea(3, 4, 5));

            Console.WriteLine(ArithmeticUtilities.NumberToDigit(5));

            Console.WriteLine(ArithmeticUtilities.FindMax(5, -1, 3, 2, 14, 2, 3));

            PrintUtilities.PrintNumber(1.3, 1);
            PrintUtilities.PrintPercent(0.75, 0);
            PrintUtilities.PrintAlignedNumber(2.30, 8);

            Console.WriteLine(GeometryUtilities.CalcDistance(3, -1, 3, 2.5));
            Console.WriteLine("Horizontal? " + GeometryUtilities.IsHorizontalLine(3, -1, 3, 2.5));
            Console.WriteLine("Vertical? " + GeometryUtilities.IsVerticallLine(3, -1, 3, 2.5));

            Student peter = new Student("Peter", "Ivanov", "Sofia", new DateTime(1992, 3, 17));

            Student stella = new Student("Stella", "Markova", "Vidin", new DateTime(1993, 11, 3));

            Console.WriteLine("{0} older than {1} -> {2}", peter.FirstName, stella.FirstName, peter.IsOlderThan(stella));
        }
开发者ID:DimitarGaydardzhiev,项目名称:TelerikAcademy,代码行数:22,代码来源:StartingPoint.cs


注:本文中的Student.IsOlderThan方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。