InstagramTwitterSnapChat


 
وصف

العودة   منتديات سكاو > الكليات الجامعية > منتدى كلية الحاسبات وتقنية المعلومات > المنتدى العام لكلية الحاسبات وتقنية المعلومات
التسجيل مشاركات اليوم البحث
   
   


المنتدى العام لكلية الحاسبات وتقنية المعلومات قسم خاص بالمواد العامة و الطلاب غير المتخصصين بكلية الحاسبات وتقنية المعلومات

الى Mr Ahmad مشروع(project) في الجافا لي 3 ايام احاول فيه والله مرة ماقدرت وطفشت

المنتدى العام لكلية الحاسبات وتقنية المعلومات

إضافة رد
 
أدوات الموضوع إبحث في الموضوع انواع عرض الموضوع
منتديات طلاب وطالبات جامعة الملك عبد العزيز منتديات طلاب وطالبات جامعة الملك عبد العزيز
  #1  
قديم 03-12-2010, 01:11 PM

وليد احمد وليد احمد غير متواجد حالياً

جامعي

 
تاريخ التسجيل: Nov 2010
نوع الدراسة: إنتظام
المستوى: الثالث
الجنس: ذكر
المشاركات: 4
Skaau.com (15) الى Mr Ahmad مشروع(project) في الجافا لي 3 ايام احاول فيه والله مرة ماقدرت وطفشت


السلام عليكم ورحمة الله وبركاته

عندنا project مشروع في الجافا وحاولت احله لكن مو مفهوم شي يعني مادري كم class عندي, الي اعرفه ان output تكون في الكلاس الرئيسية لكن المشكلة في ال method ومثل كذا جدا اعاني صعوبة فيه


وهذا السؤال اخوي مستر احمد:

Write a java class named as Product.java representing a product you purchase from a supermarket. This class should have the following information about the Product:
· Product Name (String). (e.g. Milk , Chocolate, Tea e.t.c.)
· Company Name (String) (Al-marai, Galaxy , Lipton e.t.c)
· Make Date (Date). (Date of Make of Almarai Milk printed on the Bottle )
· Product Count( int) ( No of Products in the supermarket e.g. 5 )
Customer can visit and purchase the products from the supermarket. When the customer purchase a product its date of expiry must be displayed which is 1 week from the Make Date. Let’s assume that The Super Market has 5 different Products.

The Products class should have eight methods

· setProductName (String name) for setting the name of the Product.
· getProductName ( ) for returning the name of the Product.
· setCompanyName(String name) for setting the name of the Company of a Product.
· getCompanyName ( ) for returning the name of the Company of a Product.
· check ( ) for checking the availability of a Product in the super Market.
· setMakeDate (Date) for setting the Make date of a Product.
· getMakeDate (Date) for returning the Make date of a Product.
· toString() for printing a report that contains all of Products purchased from the super market.


Write a Java application (Main class) called ProductTest.java that lets the user to create six Objects of Product Class and then prints a report that contains all the five products purchased by a customer.





Sample output:

Enter name of First Product you want to Purchase: Milk
Enter the Product Company Name: Al-marai
You can purchase the Al-marai Milk
You purchased this product on 11-07-2010
This Product will expire after 1 week

Enter name of Second Product you want to Purchase: Chocolate
Enter the Product Company Name: Galaxy
You can purchase the Chocolate Galaxy
You purchased this product on 11-07-2010
This Product will expire after 1 week

Enter name of Third Product you want to Purchase: Tea
Enter the Product Company Name: Lipton
You can purchase the Tea Lipton
You purchased this product on 11-07-2010
This Product will expire after 1 week

Enter name of Fourth Product you want to Purchase: Laban
Enter the Product Company Name: Nadec
You can purchase the Nadec Laban
You purchased this product on 11-07-2010
This Product will expire after 1 week

Enter name of Fifth Product you want to Purchase: Yoghurt
Enter the Product Company Name: Al-marai
You can purchase the Al-marai Yoghurt
You purchased this product on 11-07-2010
This Product will expire after 1 week

Enter name for Sixth Product Purchased: Labnah
Enter the Product Company Name: Nadec
Sorry Nadec Labnah is out of order
رد مع اقتباس

 

منتديات طلاب وطالبات جامعة الملك عبد العزيز منتديات طلاب وطالبات جامعة الملك عبد العزيز
قديم 03-12-2010, 02:12 PM   #2

Mr.Ahmad

عضو هيئة تدريس

الصورة الرمزية Mr.Ahmad

 
تاريخ التسجيل: Jul 2008
كلية: كلية الحاسبات وتقنية المعلومات
التخصص: IT
نوع الدراسة: عضو هيئة تدريس
المستوى: متخرج
البلد: جــــدة
الجنس: ذكر
المشاركات: 2,477
افتراضي رد: الى Mr Ahmad مشروع(project) في الجافا لي 3 ايام احاول فيه والله مرة ماقدرت وطفشت

وعليكم السلام ورحمة الله وبركاته .

تم شرح مشروع السنة السابقة , وهو شبيه جداً بهذا , تفضل :
http://www.skaau.com/vb/showthread.php?t=187829

بالتوفيق .

 

توقيع Mr.Ahmad  

 

سبحان الله وبحمد ,,, سبحان الله العظيم
الحمد لله كما ينبغي لجلال وجهه وعظيم سلطانه .
اللهم صل على محمد وعلى آل محمد كما صليت على إبراهيم وعلى آل إبراهيم إنك حميد مجيد . اللهم بارك على محمد وعلى آل محمد كما باركت على إبراهيم وعلى آل إبراهيم إنك حميد مجيد.

 

Mr.Ahmad غير متواجد حالياً   رد مع اقتباس
 

منتديات طلاب وطالبات جامعة الملك عبد العزيز منتديات طلاب وطالبات جامعة الملك عبد العزيز
قديم 03-12-2010, 06:40 PM   #3

وليد احمد

جامعي

 
تاريخ التسجيل: Nov 2010
نوع الدراسة: إنتظام
المستوى: الثالث
الجنس: ذكر
المشاركات: 4
افتراضي رد: الى Mr Ahmad مشروع(project) في الجافا لي 3 ايام احاول فيه والله مرة ماقدرت وطفشت

طيب اخوي هو في نهايةالسؤال يقلي اسس يعني create 6 object والي موجودة في ال product class اربعه بس؟؟ ايش الاثنين الي باقية؟

 

وليد احمد غير متواجد حالياً   رد مع اقتباس
 

إضافة رد


تعليمات المشاركة
لا تستطيع إضافة مواضيع جديدة
لا تستطيع الرد على المواضيع
لا تستطيع إرفاق ملفات
لا تستطيع تعديل مشاركاتك

BB code is متاحة
كود [IMG] متاحة
كود HTML معطلة

الانتقال السريع

 


الساعة الآن 12:47 AM


Powered by vBulletin® Version 3.8.9 Beta 3
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Ads Organizer 3.0.3 by Analytics - Distance Education

أن كل ما ينشر في المنتدى لا يمثل رأي الإدارة وانما يمثل رأي أصحابها

جميع الحقوق محفوظة لشبكة سكاو

2003-2023