BaşlayınÜcretsiz başlayın

Code tidying

Having a consistent style is crucial as it makes your code easier to understand and reduces bugs. Sadly, no-one told the author of the function below. The function f() fails the lint check.

To see the output of the lint, submit the answer. The lint output gives the line and column. E.g. 2:17 refers to line = 2 and column = 17.

Bu egzersiz, kursun bir parçasıdır

Defensive R Programming

Kursa Göz Atın

Egzersiz talimatları

  • Fix the function according to the feedback received.

Uygulamalı etkileşimli egzersiz

Bu egzersizi bu örnek kodu tamamlayarak deneyin.

# Fix the code
f<-function(x,y,z) {
x+y+z
}
Kodu Düzenle ve Çalıştır