float h;
float t;
float result;
float tableau[10][2];


#include "DHT.h"

#define DHTPIN 15
#define DHTTYPE DHT22
DHT dht(DHTPIN, DHTTYPE);

float calc(){
float resultat = tableau[0][0]+tableau[0][1];
return(resultat);
}

float update_tableau(int temp, int hum){
//for (int i=0; i<7; i++);
temp = tableau[1][0];
hum = tableau[1][1];
}

float temp(){
float temperature = dht.readTemperature();
return(temperature);
}


float hum(){
float humidite = dht.readHumidity();
return(humidite);
}

void setup() {
  Serial.begin(115200);
   dht.begin();
}

void loop() {

Serial.println("actuel");  
tableau[0][0]= temp();
Serial.println(tableau[0][0]);
tableau[0][1] = hum();
Serial.println(tableau[0][1]);
 
tableau[1][0] = tableau[0][0];
tableau[1][1] = tableau[0][1];

Serial.println("2eme tableau");
Serial.println(tableau[1][0]);
Serial.println(tableau[1][1]);



tableau[2][0] = tableau[1][0];
tableau[2][1] = tableau[1][1];

Serial.println("3eme tableau");
Serial.println(tableau[2][0]);
Serial.println(tableau[2][1]);

delay(2000);
}