Dart编程实例 - 相等和关系操作符

void main() {

   var num1 = 5;

   var num2 = 9;

   var res = num1>num2;

   print('num1 greater than num2 ::  ' +res.toString());

   res = num1<num2;

   print('num1 lesser than  num2 ::  ' +res.toString());

   res = num1 >= num2;

   print('num1 greater than or equal to num2 ::  ' +res.toString());

   res = num1 <= num2;

   print('num1 lesser than or equal to num2  ::  ' +res.toString());

   res = num1 != num2;

   print('num1 not equal to num2 ::  ' +res.toString());

   res = num1 == num2;

   print('num1 equal to num2 ::  ' +res.toString());

}

本文转自:http://codingdict.com/article/23407

Dart编程实例 - 相等和关系操作符的更多相关文章

  1. Dart编程实例 - 类型测试操作符 is!

    Dart编程实例 - 类型测试操作符 is! void main() { double n = 2.20; var num = n is! int; print(num); } 本文转自:http:/ ...

  2. Dart编程实例 - 类型测试操作符is

    Dart编程实例 - 类型测试操作符is void main() { int n = 2; print(n is int); } 本文转自:http://codingdict.com/article/ ...

  3. Dart编程实例 算术操作符

    Dart编程实例 算术操作符 void main() { var num1 = 101; var num2 = 2; var res = 0; res = num1+num2; print(" ...

  4. Dart编程实例 - Const 关键字

    Dart编程实例 - Const 关键字 void main() { final v1 = 12; const v2 = 13; v2 = 12; } 本文转自:http://codingdict.c ...

  5. Dart编程实例 - Final 关键字

    Dart编程实例 - Final 关键字 void main() { final val1 = 12; print(val1); } 本文转自:http://codingdict.com/articl ...

  6. Dart编程实例 - Dynamic 关键字

    Dart编程实例 - Dynamic 关键字 void main() { dynamic x = "tom"; print(x); } 本文转自:http://codingdict ...

  7. Dart编程实例 - Dart 面向对象编程

    Dart编程实例 - Dart 面向对象编程 class TestClass { void disp() { print("Hello World"); } } void main ...

  8. Dart编程实例 - Enabling Checked Mode

    Dart编程实例 - Enabling Checked Mode void main() { int n="hello"; print(n); } 本文转自:http://codi ...

  9. Dart编程实例 - 第一个Dart程序

    Dart编程实例 - 第一个Dart程序 main() { print("Hello World!"); } 本文转自:http://codingdict.com/article/ ...

随机推荐

  1. Pydiction补全插件

    Pydiction不需要安装,所有没有任何依赖包问题,Pydiction主要包含三个文件. python_pydiction.vim -- Vim plugin that autocompletes ...

  2. PHP filter_id() 函数

    定义和用法 filter_id() 函数返回指定过滤器的 ID 号. 如果成功则返回过滤器的 ID 号,如果过滤器不存在则返回 NULL. 语法 filter_id(filter_name) 参数 描 ...

  3. 04-树5 Root of AVL Tree(25 分)

    An AVL tree is a self-balancing binary search tree. In an AVL tree, the heights of the two child sub ...

  4. 复位和时钟控制(RCC)

    一.系统复位 复位除了部分RCC寄存器和备份区域以外的其他所有的寄存器: 来源: NRST引脚上的低电平(外部复位) WWDG计数结束 IWDG计数结束 软件复位(通过NVIC) 低电压管理的复位 电 ...

  5. NIO模型学习笔记

    NIO模型学习笔记 简介 Non-blocking I/O 或New I/O 自JDK1.4开始使用 应用场景:高并发网络服务器支持 概念理解 模型:对事物共性的抽象 编程模型:对编程共性的抽象 BI ...

  6. mybatis PageBounds应用分页

    第一步:分页工具类 package com.smartmorse.vo; import java.util.HashMap; import java.util.List; import java.ut ...

  7. PHP面试 MySQL的高可扩展和高可用

    MySQL的高可扩展和高可用 面试题一 MySQL分表和分区的工作原理,分表和分区的使用场景和优缺点. 分区表的原理 对用户而言,分区表时一个独立的逻辑表,但是底层MySQL将其分成了多个物理子表,这 ...

  8. 31. Git与Github

    Github介绍 GitHub是一个面向开源及私有软件项目的托管平台,因为只支持git 作为唯一的版本库格式进行托管,故名gitHub. GitHub于2008年4月10日正式上线,除了Git代码仓库 ...

  9. angular.js实现二级tab切换

    <div class="guide-type"> <h3 ng-class="{true:'active', false:''}[tab == 'pc' ...

  10. Centos7防火墙使用

    修改时区 Centos7 #修改时区 timedatectl set-timezone Asia/Shanghai 开启防火墙 #添加一条规则 firewall-cmd --zone=public - ...