You can write code in languages other than R with R Markdown, e.g.
ls *.Rmd
## 4-languages.Rmd
x = 'hello, python world!' print(x.split(' '))
## ['hello,', 'python', 'world!']