Welcome to collectivesolver - Programming & Software Q&A with code examples. A website with trusted programming answers. All programs are tested and work.

Contact: aviboots(AT)netvision.net.il

Prodentim Probiotics Specially Designed For The Health Of Your Teeth And Gums

Instant Grammar Checker - Correct all grammar errors and enhance your writing

Teach Your Child To Read

Powerful WordPress hosting for WordPress professionals

Disclosure: My content contains affiliate links.

31,128 questions

40,777 answers

573 users

How to find the average value in array of integers with VB.NET

Learn & Practice SQL


70 views
asked Mar 8, 2021 by avibootz
edited Mar 8, 2021 by avibootz

1 Answer

0 votes
Imports System
Imports System.Linq

Public Module Module1
	Public Sub Main()
		Dim arr As Integer() = {6, 8, 3, 9, 2, 4, 5}

		Dim average_value = Aggregate n In arr Into Average()
		
		Console.WriteLine(average_value)
	End Sub
End Module



' run
'
' 5.28571428571429
'

 





answered Mar 8, 2021 by avibootz

Related questions

1 answer 54 views
1 answer 59 views
1 answer 78 views
...