473,320 Members | 1,817 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

un aiuto per creare un programma in visual basic

1
Salve a tutti, dovrei scrive questo programma in linguaggio visual basic.....solo che non ho molta dimestichezza con questo linguaggio.....c'è qualcuno che può darmi un aiuto o una dritta su come fare?
vi ringrazio


Un file di testo di lunghezza ignota contiene le misure di temperatura di una reazione chimica. I valori misurati hanno parte frazionaria, sono separati da uno o più spazi e sono distribuiti su più righe. La temperatura viene misurata ogni due minuti e la prima misura è relativa all’istante 0. I valori prodotti sono quindi relativi ai minuti: 0, 2, 4, 6, etc.
Si scriva un programma che chieda all’utente il nome di questo file e quello di un secondo file dove verranno scritti i risultati; quindi legga i valori dal primo file e scriva nel secondo i valori delle temperature di OGNI minuto, includendo i minuti dispari (1, 3, 5…). Poiché i valori ai minuti dispari non sono presenti nel file di input, essi devono essere calcolati facendo una media tra il valore di temperatura del minuto pari precedente e quello pari successivo. Ogni valore sia scritto su una riga a se stante. Si veda l’esempio seguente.
Contenuto del file di input:
21.2 37.4 43.4 40.2 46.12
50.33 34.6 32.5
31.2 33.2 33.4 40.23
...etc...
Contenuto del file di output:
21.2 􀃆 primo valore letto
29.3 􀃆 media tra 21.2 (valore precedente) e 37.4 (valore successivo)
37.4 􀃆 secondo valore letto
40.4 􀃆 media tra 37.4 (valore precedente) e 43. 4 (valore successivo)
43.4 􀃆 terzo valore
...etc...
Mar 19 '07 #1
0 1776

Sign in to post your reply or Sign up for a free account.

Similar topics

0
by: Mego | last post by:
Sto usando vb6 per creare un file .cub a a partire da una query: LOCATION= d:\Test.cub; SOURCE_DSN = "Provider=MSOLAP.2;Data Source=data-center;Initial Catalog=FoodMart 2000"; CREATECUBE=CREATE...
19
by: B&Wos | last post by:
Salve ragazzi, Stiamo cercando di creare un nuovo sistema operativo open source ma, abbiamo bisogno di collaboratori che ci aiutano nell' intento... se sapete programmare in C e/o in assembler o...
0
by: dangia | last post by:
Salve a tutti. Ho uno script asp per un guestbook che funziona a meraviglia se non che interpreta le date in formato USA. Oggi 7 dicembre lo fa diventare 12 luglio. Capisco molto poco di asp,...
0
by: saretta978 | last post by:
Ciao a tutti, avrei bisogno di un aiutino!!! Dovrei creare un motore di ricerca in asp, ma non appoggiato ad un database bensì un vero e èroprio motore che data una parola chiave mi tiri fuori da...
0
by: T-Mat | last post by:
Ciao a tutti! Ho creato una libreria dll con la classe PIPPO. Come faccio a collegare questa dll con un programma console utilizzando il C#?!
1
by: T-Mat | last post by:
Ciao a tutti! Ho creato una libreria dll con la classe PIPPO. Come faccio a collegare questa dll con un programma console utilizzando il C#?!
97
by: Master Programmer | last post by:
An friend insider told me that VB is to be killled off within 18 months. I guess this makes sence now that C# is here. I believe it and am actualy surprised they ever even included it in VS 2003 in...
5
by: artev | last post by:
è possibile al click creare una casella di testo nella pagina? e se si ripete il click crearene un'altra?
4
by: priyana | last post by:
How to creare for my visual basic system setup file
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.