首页 > Web开发 > 详细

angularjs 求两变量之和

时间:2017-06-01 11:48:37      阅读:357      评论:0      收藏:0      [点我收藏+]
<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 求两变量之和

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

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!