C Programming
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me

The Shed is going Social! Join us on FaceBook and Twitter and chime in on the conversation.

Go Back   Dev Shed ForumsProgramming LanguagesC Programming

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old December 26th, 2012, 07:18 AM
tigerfady11 tigerfady11 is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Dec 2012
Posts: 13 tigerfady11 Negative: is most likely a SPAMMER and a traitor to the cause. 
Time spent in forums: 3 h 49 m 15 sec
Reputation Power: 0
Exclamation Urgent C program help plz

dear readers I have done my researches and still un-able to solve this program so please I need someone to help me or even solve it but as I think we must use semaphores, forks and pipes that's what I think but no nothing else about it.can anyone solve it plz ? am not good in C language... thanks for all.

We are requested to implement a code cracking system. The system will deploy four processes (p1,p2,p3 & p4) to try to guess the password of an encrypted code.
For encryption, we consider that the formula is: C = P XOR K, where
• C = encrypted code
• P = plain text
• K = key
For decryption the formula is: P = C XOR K. So, your program will try to find K using this formula. The XOR operator is ^.
Given an encrypted code C and plain code P your program should deploy three processes to try and find the key used to encrypt the plain code. These three processes will be under the control of process P1.
All processes will send their results to process P1 and process P1 will terminate the three processes and display the encryption key and decrypted text once any of the three processes finds the key.
For simplicity we will consider that we have the original number P stored in a file called plain.txt and the encrypted code is stored in a file called cipher.txt. Consider that only numbers are stored in these files and they have a range between 0 and 100000000.
So we have P and C your program should find the key K. Consider that K is a positive number between 0 and 1000000.

Reply With Quote
  #2  
Old December 26th, 2012, 07:22 AM
ptr2void ptr2void is offline
I haz teh codez!
Dev Shed Regular (2000 - 2499 posts)
 
Join Date: Dec 2003
Posts: 2,476 ptr2void User rank is General 18th Grade (Above 100000 Reputation Level)ptr2void User rank is General 18th Grade (Above 100000 Reputation Level)ptr2void User rank is General 18th Grade (Above 100000 Reputation Level)ptr2void User rank is General 18th Grade (Above 100000 Reputation Level)ptr2void User rank is General 18th Grade (Above 100000 Reputation Level)ptr2void User rank is General 18th Grade (Above 100000 Reputation Level)ptr2void User rank is General 18th Grade (Above 100000 Reputation Level)ptr2void User rank is General 18th Grade (Above 100000 Reputation Level)ptr2void User rank is General 18th Grade (Above 100000 Reputation Level)ptr2void User rank is General 18th Grade (Above 100000 Reputation Level)ptr2void User rank is General 18th Grade (Above 100000 Reputation Level)ptr2void User rank is General 18th Grade (Above 100000 Reputation Level)ptr2void User rank is General 18th Grade (Above 100000 Reputation Level)ptr2void User rank is General 18th Grade (Above 100000 Reputation Level)ptr2void User rank is General 18th Grade (Above 100000 Reputation Level)ptr2void User rank is General 18th Grade (Above 100000 Reputation Level) 
Time spent in forums: 1 Month 2 Weeks 2 Days 5 h 42 m 39 sec
Reputation Power: 2194
Identical topic.

If you can't even get started, maybe you need to discuss this with your teacher before you fail.
__________________
I ♥ ManiacDan & requinix

This is a sig, and not necessarily a comment on the OP:
Please don't be a help vampire!

Reply With Quote
  #3  
Old December 26th, 2012, 07:27 AM
tigerfady11 tigerfady11 is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Dec 2012
Posts: 13 tigerfady11 Negative: is most likely a SPAMMER and a traitor to the cause. 
Time spent in forums: 3 h 49 m 15 sec
Reputation Power: 0
tnx dear, but it is my friend's issue and if he don't solve this before 2 dayz he will fail so if ya plz can help I will be really thankful! and dear bro as I told you am not good at C language at all !

Reply With Quote
  #4  
Old December 26th, 2012, 07:47 AM
tigerfady11 tigerfady11 is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Dec 2012
Posts: 13 tigerfady11 Negative: is most likely a SPAMMER and a traitor to the cause. 
Time spent in forums: 3 h 49 m 15 sec
Reputation Power: 0
please help

Reply With Quote
  #5  
Old December 28th, 2012, 02:40 AM
lhon12006 lhon12006 is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Aug 2012
Posts: 56 lhon12006 Negative: is most likely a SPAMMER and a traitor to the cause. 
Time spent in forums: 15 h 12 m 50 sec
Reputation Power: 0
you repost it right ..

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming LanguagesC Programming > Urgent C program help plz

Developer Shed Advertisers and Affiliates



Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 


Powered by: vBulletin Version 3.0.5
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.

© 2003-2013 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap