.


:




:

































 

 

 

 


3.1.1, 3.1.2, 3.1.3




3.3.5) 3.1.1, 3.1.2,

3.1.3

(. 4.3.7-5

4.3.7-6):

 

Option Strict On Imports System.Math Public Class Form1 ', Function func(ByVal x As Double, ByVal y As Double)As Double Dim z As Double ' z = (0.002 - Exp(x ^ y)) / ((100 - y) * (x + 2)) Return z ' End Function Private Sub Button1_Click(sender As Object, _ e As EventArgs)Handles Button1.Click Dim x, y, z, m, n As Double, p As Single, _ k As Integer Dim s1, s2 As String x = CDbl(TextBox1.Text) y = CDbl(TextBox2.Text) z = func (x, y) ' p = CSng(z) k = CInt(z) m = Fix(z) n = Int(z) s1 = CStr(z) s2 = CStr(p) TextBox4.3.Text = CStr(z) TextBox4.Text = CStr(k) TextBox5.Text = CStr(m): TextBox6.Text = CStr(n) TextBox7.Text = CStr(p): TextBox8.Text = CStr(z + p) TextBox9.Text = s1 + s2 End Sub Private Sub Button2_Click(sender As Object, _ e As EventArgs)Handles Button2.Click End End Sub END Class

 

. .1.3-5. 3.1.1

 

Option Strict On Imports System.Math Public Class Form1 Sub proc1(ByVal x As Double, ByVal y As Double, _ ByRef z As Double) z = (0.002 - Exp(x ^ y)) / ((100 - y) * (x + 2)) End Sub Private Sub Button1_Click(sender As Object,e As EventArgs)_ Handles Button1.Click Dim x, y, z, m, n As Double, p As Single, k As Integer Dim s1, s2 As String x = CDbl(TextBox1.Text) y = CDbl(TextBox2.Text) proc1(x, y, z) ' p = CSng(z) k = CInt(z) m = Fix(z) n = Int(z) s1 = CStr(z): s2 = CStr(p) TextBox4.3.Text = CStr(z) TextBox4.Text = CStr(k) TextBox5.Text = CStr(m) TextBox6.Text = CStr(n) TextBox7.Text = CStr(p) TextBox8.Text = CStr(z + p) TextBox9.Text = s1 + s2 End Sub Private Sub Button2_Click(sender As Object, _ e As EventArgs)Handles Button2.Click End End Sub End Class

 

. .1.3-6. 3.1.2


 

Option Strict On Imports System.Math Public Class Form1 ' Dim x As Double, y As Double, z As Double Sub proc2() ', z = (0.002 - Exp(x ^ y)) / ((100 - y) * (x + 2)) End Sub Private Sub Button1_Click(sender As Object, _ e As EventArgs)Handles Button1.Click Dim m, n As Double, p As Single, k As Integer Dim s1, s2 As String x = CDbl(TextBox1.Text) y = CDbl(TextBox2.Text) proc2() ' p = CSng(z) k = CInt(z) m = Fix(z) n = Int(z) s1 = CStr(z) s2 = CStr(p) TextBox4.3.Text = CStr(z) TextBox4.Text = CStr(k) TextBox5.Text = CStr(m) TextBox6.Text = CStr(n) TextBox7.Text = CStr(p) TextBox8.Text = CStr(z + p) TextBox9.Text = s1 + s2 End Sub Private Sub Button2_Click(sender As Object, _ e As EventArgs)Handles Button2.Click End End Sub End Class

. .1.3-7. 3.1.3

 


3.4. :

1) , , . 4.2.8-11.

2) .

3) - (<F11>), . - .

4) - Return z , .

5) , .

6) ,

 

Sub proc1(ByVal x As Double, ByVal y As Double, ByRef z As Double) Sub proc1(ByVal x As Double, ByVal y As Double, ByVal z As Double)

, .

7) .

8) ,





:


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


:

:

, ,
==> ...

744 - | 737 -


© 2015-2024 lektsii.org - -

: 0.013 .