![]()  | 
	
 
  | 
| 
	 | 
| 
		 
			 
			#1  
			
			
			
			
		 
		
		
	 | 
||||
		
		
  | 
||||
| 
	
	
		
			
			 Есть такой код:  
		
	
		
		
		
		
		
	
		
		
	
	
	Код: 
	a1 := StrToInt(StringReplace(Edit1.Text,',','.',[]));
  b1 := StrToInt(StringReplace(Edit2.Text,',','.',[]));
  c1 := StrToInt(StringReplace(Edit3.Text,',','.',[]));
  d1 := StrToInt(StringReplace(Edit4.Text,',','.',[]));
    k1 := (a1 +  b1 +  c1 +  d1); //количество оценок
    if k1<>0 then f1 := (2 * a1 + 3 * b1 + 4 * c1 + 5 * d1)/k1;  //расчет
      str:=FloatToStrF(f1,ffFixed,1,1);
       if Pos(',',str)<>0 then str[Pos(',',str)]:='.';
         label7.Caption:=str; | 
| 
		 
			 
			#2  
			
			
			
			
		 
		
		
	 | 
||||
		
		
  | 
||||
| 
	
	
		
			
			 Код: 
	if str='0.0' then str:='0';  | 
| 
		 
			 
			#3  
			
			
			
			
		 
		
		
	 | 
||||
		
		
  | 
||||
| 
	
	
		
			
			 А куда мне это в моем коде вписать?) 
		
	
		
		
		
		
		
	
		
		
	
	
	 | 
| 
		 
			 
			#4  
			
			
			
			
		 
		
		
	 | 
||||
		
		
  | 
||||
| 
	
	
		
			
			 Перед 
		
	
		
		
		
		
			
		
		
		
		
	
		
		
	
	
	Код: 
	label7.Caption:=str;  | 
| 
		 
			 
			#5  
			
			
			
			
		 
		
		
	 | 
||||
		
		
  | 
||||
| 
	
	
		
			
			 Это код, который складывает по вертикали ячейки в StringGrid: 
		
	
		
		
		
		
		
	
		
		
	
	
	Код: 
	for i:=1 to 25 do
   begin
      if (SG3.Cells[2,i]=' ') or (SG3.Cells[8,i]=' ') or (SG3.cells[14,i]=' ') or       (SG3.cells[20,i]=' ') then SG3.cells[26,i]:='0' else
        begin
          try
             summ:=(StrToFloat(SG3.Cells[2,i])+StrToFloat(SG3.cells[8,i])+
                         StrToFloat(SG3.cells[14,i])+
                         StrTofloat(SG3.cells[20,i]))/4;
            SG3.Cells[26,i]:=FloatToStrF(summ,ffFixed,1,1);
            if SG3.Cells[26,i]='0.0' then SG3.Cells[26,i]:='0';
          except
            SG3.Cells[26,i]:='0.0';
          end;
        end;
   end;![]()  | 
| 
		 
			 
			#6  
			
			
			
			
		 
		
		
	 | 
||||
		
		
  | 
||||
| 
	
	
		
			
			 Проверять что введено в нужной ячейке. 
		
	
		
		
		
		
			
		
		
		
		
	
		
		
	
	
	 | 
| 
		 
			 
			#7  
			
			
			
			
		 
		
		
	 | 
||||
		
		
  | 
||||
| 
	
	
		
			
			 Цитата: 
	
  |