Your first method · طريقتك الأولى
This page needs a recent browser (with SharedArrayBuffer support). Please update Chrome, Edge, Firefox or Safari to the latest version. · تحتاج هذه الصفحة إلى متصفح حديث (يدعم SharedArrayBuffer). يرجى تحديث Chrome أو Edge أو Firefox أو Safari إلى أحدث إصدار.
English
Your first method
Now write a method. Don't write main — the checker calls your method with several inputs and checks what you return. Complete twice so it returns n times two.
العربية
أول دالة لك
الآن اكتب دالة. لا تكتب main — يقوم الفاحص باستدعاء دالتك بإدخالات متعددة ويتحقق مما return. أكمل twice بحيث تعيد الضرب في n.
Complete twice(int n) so it returns n times two. Don't write main. · أكمل twice(int n) لتُرجع n مضروباً في اثنان. لا تكتب main.
Click Run to see the output here. · اضغط تشغيل لرؤية المخرجات هنا.