码迷,mamicode.com
首页 > Web开发 > 详细

angularjs 求两变量之和

时间:2017-06-01 12:09:37      阅读:150      评论:0      收藏:0      [点我收藏+]

标签:png   mod   http   class   sum   div   back   htm   tps   

<img src="https://angularjs.org/img/AngularJS-large.png" height="50px" weight="50px"/>

<h3>Sum of two Numbers using AngularJS</h3>

<div ng-app="">
     <h3>Using Double Negation</h3>

    <p>First Number:
        <input type="text" ng-model="a" />
    </p>
    <p>Second Number:
        <input type="text" ng-model="b" />
    </p>
    <p>Sum: {{ a -- b }}</p>
     <h3>Using Input Type Number</h3>

    <p>First Number:
        <input type="number" ng-model="c" />
    </p>
    <p>Second Number:
        <input type="number" ng-model="d" />
    </p>
    <p>Sum: {{ c + d }}</p>
</div>

  

angularjs 求两变量之和

标签:png   mod   http   class   sum   div   back   htm   tps   

原文地址:http://www.cnblogs.com/liucong7708/p/6928059.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!