Wednesday, September 28, 2011

Math Problem

One of the mathematical problems that I’ve seen today and decided to solve it :)
Problem:
If we list all the natural numbers below 10 that are multiples of 3 or 5, we get 3, 5, 6 and 9. The sum of these multiples is 23.
Find the sum of all the multiples of 3 or 5 below 1000.

Solution (This is my own solution – you can solve it using another way)
-The nearest multiple of 3 below to 1000 is 999 then we have 999/3 = 333 multipliers –>1 –> “m”
-The nearest multiple of 5 below to 1000 is 995 then we have 995/5 = 199 multipliers –>2
--> from step “1” we have:
The sum of all multiples of a Number n = (the number in the set “n”) x (The mean of the Set “o”)
n = 3 ,  o = m(m + 1) / 2 = 333(333 + 1)/2 = 333 (334)/2 = 55611

then the sum = 3 * 55611 = 166833 –> 3
--> from step “2” we have:
n = 5, o = 199 (200) / 2 = 19900
then the sum = 5 * 19900 = 99500 –> 4
From step “3” and step “4” we have:
the total sum of all multiplies of 3 and not or 5 below 1000 = 166833 + 99500 = 266333
We want now to remove the common multipliers between the 3 and 5 –> 3 * 5 = 15 –> n = 15
-The nearest multiple of 15 below to 1000 is 990 then we have 990/15 = 66 multipliers
then the sum = 15 * 66(67)/2 = 33165

Finally we got, the total sum of all multiples of 3 or 5 below 1000 = 266333 – 33165 = 233168

hope you enjoyed it too;
Thanks;
Mohamed Adel
For More Info Please Visit: http://projecteuler.net

Wednesday, September 21, 2011

How to Block “Facebook” on all your browsers

 


Sometimes, Facebook is wasting a lot of our working, studying or life time;

I will talk today about how to block “Facebook” on all your browsers;

Sometimes, The Normal block method used from the “Internet Options” isn’t working on some sites like Facebook.

Today, I’ll teach you how to block the Facebook Site from the Host File;

1-Open the C:\Windows\System32\drivers\etc folder

2-Right Click on the hosts file and Open it with Notepad or any text editor

3-Search for this line in the file:  #    127.0.0.1       localhost

4-Add these 2 lines after it:

127.0.0.1 facebook.com
127.0.0.1
www.facebook.com

(See the Figure)


5-Save the file.

  • Sometimes you can’t overwrite the host file when saving, follow these steps:
  1. Save the host file after editing it on any location you know on you PC
  2. From Windows Explorer Open Tools –> Folder Options –> View then Uncheck the “Hide extensions for known file types”.
  3. remove any additional extensions added to the file that you have created e.g. hosts.txt –> hosts remove the .txt by renaming the file.
  4. copy your host file from the location you know and replace the file in the C:\Windows\System32\drivers\etc folder.
  5. Say ByeBye Facebook

Share it if you believe that it’s important.

 
  For More Info Please Visit: 10 Reasons to leave Facebook  

Sunday, September 18, 2011

WPF VS Silverlight

 


What is the difference between WPF and Silverlight?

I’ve heard many developers talking about this topic;

Here’s a Good research about WPF VS Silverlight that answers this famous question

done by Eng. Ibraheem Osama Mohamed (MSP Egypt – Helwan Microsoft Tech-Club)

 

 http://j.mp/WPF_vs_SL (PDF Version – 232 KB)

 
  For More Info Please Visit: Helwan Microsoft Tech-Club Page on Facebook  

Wednesday, September 7, 2011

How to install the Windows Phone Developer Tools on Windows Server 2008

 


The Windows Phone Developer Tools are not officially supported on operating systems other than Windows Vista or Windows 7. 

There is a way you can work around the Windows Server 2008 setup block if needed.  Please note that this is not officially supported, so if you try these steps, you are doing so at your own risk.

  1. Download the Windows Phone Developer Tools web installer and save it to your hard drive
  2. Extract the contents of the setup package by running vm_web.exe /x and choosing a path to extract to
  3. Go to the folder you extracted to in step 2 and open the file baseline.dat in notepad
  4. Look for the section named [gencomp7788]
    Note - you have to change this exact section - this is the one that controls the OS version blocking behavior in Windows Phone Developer Tools setup.
  5. Change the value InstallOnLHS from 1 to 0
  6. Change the value InstallOnWin7Server from 1 to 0
  7. Save and close baseline.dat
  8. Run setup.exe /web from the folder you extracted to in step 2
    Note - please make sure that you include the /web command line parameter in step 8.  If you don't, setup will not attempt to download the packages it needs to install, and it will fail to install correctly as a result.
 
  For More Info Please Visit: Aaron Stebner's WebLog  

Monday, September 5, 2011

Installing SQL Server 2008 R2 (SQL Administration Part 2 - 1)

 

Hardware Requirements:

1-For SQL Server 2008 R2 Standard Edition “32 Bit”

a-Processor
-Pentium 1.0 GHZ minimum processing power

-2.0 GHZ or higher “recommended”

b-Operating System:

-XP SP3 or higher

b-Memory

-MIN 1GB.

-4 GB or more“recommended”

-MAX 64 GB

-Express Editions requires 192 MB and recommends 512 MB RAMS


2-For SQL Server 2008 R2 Standard Edition “64 Bit”

a-Processor
-Pentium 1.4 GHZ minimum processing power

-2.0 GHZ or higher “recommended”

b-Operating System:

-XP Professional SP2 64x – Windows Server 2003 SP2 64x or higher

b-Memory

-MIN 1GB.

-4 GB or more“recommended”

-MAX 64 GB

-Express Editions requires 192 MB and recommends 512 MB RAMS



Disk Space Required (32 bit and 64 bit)

verify that you have at least 3.6 GB of available disk space on the system drive for these files before starting the SQL Server installation.

-Database Components (Engine – data files – Replication – Full Text Search): 711 MB

-Analysis Services: +90 MB (Average 345 MB)

-Reporting Services: +120 MB (Average 304 MB)

-Integration Services: +120 MB (Average 591 MB)

-Client Components: +850 MB (Average 1823 MB)

 
  For More Info and to view the other SQL Server 2008 R2 Editions HW and SW Requirements Please Visit: Hardware and software requirements for installing SQL Server 2008 R2  

Search This Blog