السلام عليكم ورحمة الله وبركاته ...
عندي مشكلة بسيطة في كود جافا .... ياليت لو في أحد يقدر يساعدني ...ماعرفت كيف أكلمه
المسألة هيه عبارة عن :
Write a Java application program that draws lines in random lengths and random colors. Hint: you can use the Math.random() method to generate a random number x where 0 ≤ x < 1
والكود اللي أنا كاتبتنه ... بس مب كامل
import java.awt.*;
import java.awt.event.*;
import javax.swing.*;
public class DrawLine extends JFrame
{
public DrawLine()
{
super("Drawin Lines");
setSize(300,400);
setVisible(true);
}
public void paint(Graphics g)
{
super.paint(g);
}
}
ياليت لو أحد يقدر يساعدني ... أنا ماعرفت كيف أكتب Math.random () method
by the way i am using Borland JBuilder9
and thanx alot