Skip to content

Instantly share code, notes, and snippets.

View MohamedRamadanSaad's full-sized avatar

Mohamed Ramadan MohamedRamadanSaad

  • Vodafone
  • Cairo
View GitHub Profile
@MohamedRamadanSaad
MohamedRamadanSaad / files
Created May 31, 2015 23:39
Files i/o in C++ all operations insert , delete, view , update
#include<iostream.h>
#include<fstream.h>
class Inventory{
public:
char Prouduct_id[5];
char Prouduct_name[10];
char Prouduct_ammount[5];
@MohamedRamadanSaad
MohamedRamadanSaad / calcu
Created May 31, 2015 23:28
JAVA , Calculation + GUI
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package calcu;
import javax.swing.*;
import java.awt.event.*;
import java.awt.event.ActionEvent;
import java.io.*;
import java.lang.ArithmeticException;
@MohamedRamadanSaad
MohamedRamadanSaad / simple calc
Last active August 29, 2015 14:22
C++ , calculation by do while , switch
#include <iostream>
using namespace std;
int main()
{
cout<<"********************************************************************************\n";
cout<<"**** Designed By: Mohamed Ramadan The Caculation *****\n";
cout<<"********************************************************************************\n";
int x[2];
char y;
@MohamedRamadanSaad
MohamedRamadanSaad / C to F convertion
Created May 31, 2015 23:16
Celsius to Fahrenheit , C++
#include<iostream>
using namespace std;
int main()
{
int f,e,w;
cout<<"Please...Enter The Fahrenheit Degree That You Want to Convert It and press enter\a\n";
cout<<"\t\t\t\t\tF =";
cin>>f;
@MohamedRamadanSaad
MohamedRamadanSaad / simple calc
Created May 31, 2015 23:11
Simple Calculator Brginner , C++ 2011
#include <iostream>
using namespace std;
int main ()
{
cout<<"\t\t\t\t{Mohamed Ramadan Saad}"<<endl;
cout<<"\t\t\t{Faculty of Computer and Information}"<<endl;
cout<<"\t\t\t\t{From....Sadat....City}"<<endl;
cout<<"................................................................................"<<endl;
cout<<"\t\t\t\t........................."<<endl;
cout<<"\t\t\t\t.\tCalculator\t."<<endl;
@MohamedRamadanSaad
MohamedRamadanSaad / Area For Circle
Created May 31, 2015 23:02
Area For Circle , C++
#include<iostream>
using namespace std;
int main()
{
cout<<"\t\t\t\tMohamed Ramadan Saad\n";
cout<<"\t\t\tFaculty Of Computer And Information\n";
cout<<"\t\t\t\tFrom... Sadat...City\n";
cout<<"................................................................................\n";
cout<<"This Program Is For Calculating The Area And The Circumference For Circle \n ";
cout<<"...............................................................................\n";
@MohamedRamadanSaad
MohamedRamadanSaad / plus_minus_first_app
Created May 19, 2015 20:53
Simple calculator , Dialog Activity , Android
package com.example.first;
import android.os.Bundle;
import android.app.Activity;
import android.view.Menu;
import android.view.View;
import android.view.View.OnClickListener;
import android.view.Window;
import android.widget.Button;
import android.widget.EdgeEffect;
@MohamedRamadanSaad
MohamedRamadanSaad / ALC
Created May 19, 2015 20:51
Android Life Cycle
package com.example.second_app;
import android.os.Bundle;
import android.app.Activity;
import android.content.Intent;
import android.view.Menu;
import android.view.View;
import android.widget.Button;
import android.widget.Toast;
@MohamedRamadanSaad
MohamedRamadanSaad / part of the method
Created May 19, 2015 20:48
Connect the solitaire image view by an id to access them , manually
public void initGame()
{
field1=0;
field2=0;
field3=0;
if(random_first_im1==1||random_first_im1==3){
first_im1.setImageResource(R.drawable.one_black);
}else if(random_first_im1==2||random_first_im1==4){
first_im1.setImageResource(R.drawable.one_red);
}else if(random_first_im1==5||random_first_im1==7){
@MohamedRamadanSaad
MohamedRamadanSaad / naive
Created May 19, 2015 20:43
NLP NaiveBaise , Python
__author__ = 'Mohamed_Ramadan_PC'
f1 =open('E:\\healthy.txt','r+')
f2 =open('E:\\unhealthy.txt','r+')
f3=open('E:\\NoOfHealthy.txt','r+')
f4=open('E:\\NoOfUnHealthy.txt','r+')
def learn(food,sort):
TheMeal=food.split(" ")
for meal in TheMeal: