🚀 Hurry! Offer Ends In
00 Days
00 Hours
00 Mins
00 Secs
Enroll Now
X

नीचे दिए गए डिव टैग सामग्री कथन पर विचार करें, "उपयोगकर्ता नाम" का मान कैसे प्रिंट करें?

Consider the below div tag content statement, how to print the value of "UserName"?

<div ng-app="" ng-init="firstName='John'">
<p>Input something in the input box:</p>
<p>Name: <input type="text" ng-model="UserName"></p>
<p>You wrote: __________ </p>
</div>


A)
B)
C)
D)

Explanation:

In the given code, to print the value of the UserName using AngularJS, you need to use interpolation with double curly braces {{}}.

To display the value of UserName, you should write it like this:

{{UserName}}

So, the correct answer is:

(B) {{UserName}}.

Latest Updates