Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <!DOCTYPE html>
- <html ng-app="cfoApp">
- <head>
- <meta charset="utf-8">
- <title></title>
- <script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.5.0-rc.0/angular.min.js">
- </script>
- <script type="text/javascript">
- var app = angular.module("cfoApp", []);
- app.controller("cfoController", function($scope) {
- console.log("oi");
- });
- </script>
- </head>
- <body ng-controller="cfoController">
- <input ng-model="mat" type="number" name="name" value="0" placeholder="Matemática"><br />
- <input ng-model="port" type="number" name="name" value="0" placeholder="Português"><br />
- <input ng-model="lit" type="number" name="name" value="0" placeholder="Literatura"><br />
- <input ng-model="geo" type="number" name="name" value="0" placeholder="Geografia"><br />
- <input ng-model="hist" type="number" name="name" value="0" placeholder="História"><br />
- <input ng-model="dir" type="number" name="name" value="0" placeholder="Direitos Humanos"><br />
- <input ng-model="qui" type="number" name="name" value="0" placeholder="Química"><br />
- <input ng-model="bio" type="number" name="name" value="0" placeholder="Biologia"><br />
- <input ng-model="fis" type="number" name="name" value="0" placeholder="Física"><br />
- <input ng-model="fl" type="number" name="name" value="0" placeholder="foreign language"><br />
- <input ng-model="red" type="number" name="name" value="0" placeholder="Nota da Redação"><br />
- Result:
- <span ng-init="0">{{(((mat * 3) + (port * 3) + (lit) + (geo) + (hist) + (dir * 2) + (qui * 3) + (bio * 2) + (fis * 3) + (fl)) / 20 * 2 + red)}}</span>
- <br>Número de acertos:
- <span>{{ mat + port + lit + geo + hist + dir + qui + bio + fis + fl}}</span>
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement