.


:




:

































 

 

 

 





. , , , , , , VB.

. , , . , , - , .

, , . , , :

, ? , , - . , .

? . , , . , , , . , , , .

, . 4.2.5-7, .
. 4.2.5-9.

 

 

.4.2.5.9.

 

( Option Strict On), String Single Double Single .

, IntelliSense ( ), (. 4.2.5-10).

 

 

 

. 4.2.5-10. IntelliSense

 

. .

VB (String), (Single), . A, B C , TextBox1, TextBox2 TextBox3, String Single. CSng().

TextBox4 TextBox5 (String) CStr().

.

(. 4.2.5-11) , . 4.2.5-12.

 

Option Strict On Option Explicit On Imports System.Math Public Class Form1 Private Sub Button1_Click(ByVal sender As System.Object, _ ByVal e As System.EventArgs) Handles Button1.Click Dim A, B, C As Single Dim P, Pp, S As Single ' TextBox2 B = CSng(TextBox4.2.Text) ' TextBox1 A = CSng((TextBox1.Text)) ' TextBox3 C = CSng((TextBox3.Text)) ' P = (A + B + C) ' Pp = P / 2 ' S S = CSng((Sqrt(Pp * (Pp - A) * (Pp - B) * (Pp - C)))) ' TextBox4 TextBox4.Text = CStr(P) ' TextBox5. TextBox5.Text = CStr(S) End Sub Private Sub Button2_Click(ByVal sender As System.Object, _ ByVal e As System.EventArgs) Handles Button4.2.Click End End Sub End Class
 

 

.4.2.5-11

 

. , , , 12, 6. , .

, , , . 4.2.5-13. .

 

 

 

.4.2.5-12. :

=3, =4, =5

 

 

.4.2.5-13 : =10, =2, =1

 

, , : . , . . . .

 





:


: 2016-11-18; !; : 511 |


:

:

,
==> ...

1856 - | 1633 -


© 2015-2024 lektsii.org - -

: 0.008 .