Updating a file rondom access

Posted by / 31-Aug-2017 08:14

Updating a file rondom access

Writeline ("enter the radius of circle") r= console.readline() console.writeline("enter the depth of square") d= console.readline() console.writeline("enter the breadth of square") b= console.readline() p= area(r) p1= area(d,b) console.writeline("area of circle: ", p) console.writeline("area of square: ", p1) end sub function area(byval r as integer) as integer return r*r end function function area(byval d as double, byval b as double) as double return d*b end function end module 2.8 Write a program to implement arithmetic calculator using console which handles Divide by Zero Exception and Arithmetic Exception.

Reading and writing files involves transferring a sequence of bytes between your code and the underlying disk.

Net Imports System Module m Public Class base Dim a As Integer Public Sub dis() My Class.printdata() End Sub Public Overridable Sub printdata() console.writeline("Base Class") End Sub End Class Public Class derive Inherits base Public Overloads Sub dis(By Val s As String) My Base.dis() console.writeline(s) End Sub Public Overrides Sub printdata() console.writeline("Derive Class") End Sub End Class Sub main() Dim d As New derive d.printdata() d.dis("By Derive Class method") End Sub End Module //some more programs about 10 more // 2.1 Write a program to give example of implicit and explicit type conversions.2.1 Write a program which reads date of birth and finds age and zodiac sun sign. To Char(j) s2 = a Else s2 = s2 s(i) End If Next Catch ex As Exception Console. Write Line("Lowercase of " & s1 & " is " & s2) End Try End Sub Public Sub str Title(By Val s As String) Dim s1, s2 As String Dim i, j As Integer Dim a As Char Dim f As Integer s1 = s f = 0 s2 = "" Try If Asc(s1(0)) = 65) And f = 0 Then a = s(i) j = asc(a) 32 a = Convert. Visual Basic Imports System Module m Sub main() Dim i, j As Integer Dim s(1), str, st As String i = 0 Do Console.writeline("Enter string") str = console.readline() If strcomp(str, "end") = 0 Then Exit Do Else Re Dim Preserve s(i 1) s(i) = str End If i = i 1 Loop For i=0 to ubound(s) For j=0 to ubound(s) If strcomp(s(i), s(j)) = 0) p = r.readline() End While c = ceaser(p, key) w.write("ceaser ciphertext: ") w.writeline(c) w.flush() w.close() console.write Line("ceaser cipher is done in given file") End Sub Function ceaser(By Val s As String, By Val k As Integer) As String Dim i, t As Integer Dim c As String c = "" For i = 0 To len(s) - 1 t = (k Mod 26) asc(s(i)) If (t 122) Then t = t - 26 c = c chr(t) Else c = c chr(t) End If Next Return c End Function End Module 2.7 Write a program to demonstrate the use of mybase and myclass.Module Module1 Sub Main() Dim s As Date Dim d, m, y, y0 As Double System. Write Line("Enter your date of birth in MM/DD/YYYY format") s = System. Read Line() y = datepart("YYYY", s) y0 = datepart("YYYY", today) System. To Char(j) s2 = a Else s2 = s(i) End If Next Catch ex As Exception Console. Write Line("Title case of is: " & s2) End Try End Sub End Module 2.3 Write a program to sort a dynamic array of strings. Imports System Module m Public Class base Dim a As Single Public Sub New(By Val aa As Single) a = aa End Sub Public Sub dis() My Class.printdata() End Sub Public Overridable Sub printdata() console.writeline("Base Class") End Sub End Class Public Class derive Inherits base Sub New(By Val b As Single) My Base.new(b) End Sub Public Overrides Sub printdata() console.writeline("Derive Class") End Sub End Class Sub main() Dim d As New derive(10) d.printdata() d.dis() End Sub End Module 2.8 Write a program to demonstrate delegates with VB .All of them do essentially the same thing but in slightly different ways.Some technologies require you to read and write file data sequentially, while others may allow you to jump around and operate on only part of a file.

updating a file rondom access-84updating a file rondom access-11updating a file rondom access-76

One thought on “updating a file rondom access”

  1. Also Read: Bette Midler Demands Apology From Geraldo Rivera, Says He Drugged and ' Groped Me' However, in his tweets on Friday morning, Rivera pointed out that, “Although I recall the time Bette Midler has alluded to much differently than she, that does not change the fact that she has a right to speak out & demand an apology from me, for in the very least, publically [sic] embarrassing her all those years ago,” he said.