Tamamlanmış

speed up a php script

Hello bidders,

Please only bid if you have your own server to test the code on thanks.

I have a php code which is working but sometimes it takes too long to execute.

Fatal error: Maximum execution time of 30 seconds exceeded in

I have tried adding ini_set('max_execution_time', 300); //300 seconds = 5 minutes but that results in using up the memory and the rest of my page doesn’t load.

Basicly with my code i can add any one word to it, 9 letter words seem to work but any word larger than 9 letters the code can’t execute fast enough due to there being too many combinations to search in the loop.

See examples here: [login to view URL]

"stop" works fine but "abbreviation" is too long

is there anyway to speed up the following code

<ol>

<?php

$checked = array();

function permute($str, $l, $r, $pspell_link)

{

global $checked;

if ($l == $r) {

if (empty($checked[$str])) {

$checked[$str] = true;

if (pspell_check($pspell_link, $str)) {

echo "<li><strong>" . ucwords($str) . "</strong></li>\n";

};

}

} else {

for ($i = $l; $i <= $r; $i++) {

$str = swap($str, $l, $i);

permute($str, $l + 1, $r, $pspell_link);

$str = swap($str, $l, $i);

}

}

}

function swap($a, $i, $j)

{

$temp;

$charArray = str_split($a);

$temp = $charArray[$i];

$charArray[$i] = $charArray[$j];

$charArray[$j] = $temp;

return implode($charArray);

}

$str = "$anagram";

$n = strlen($str);

$pspell_link = pspell_new("en");

permute($str, 0, $n - 1, $pspell_link);

?>

</ol>

Beceriler: PHP, Javascript, MySQL, Yazılım Mimarisi, HTML

Daha fazlasını gör: php script speed test, php script connection speed tester, free php script speed test, download php script speed test site, speed test site php script, php script speed testen, php script test download speed, php script test download speed internet, php speed upload script, bandwidth speed test php script, php script work server, check speed php script, dsl speed php script, write upload speed php script

İşveren Hakkında:
( 27 değerlendirme ) chichester, United Kingdom

Proje NO: #21114819

Seçilen:

aipwork

Hello. Your algorithm does not improve cardinally and it depends directly on the length of a word. You use a full permutation search, which has a complexity of n! (See [login to view URL]) For exa Daha Fazla

1 gün içinde %selectedBids___i_sum_sub_4%%project_currencyDetails_sign_sub_5% GBP
(0 Değerlendirme)
0.0

Bu iş için 59 freelancer ortalamada £125 teklif veriyor

vw580939vw

Dear Sir, We can have the code access along with website (i.e. database, CSS, HTML ) etc, so we can review this closely? If you can set up things on separate development server, will do too. We offer GBP7/hr of workin Daha Fazla

£40 GBP in 7 gün içinde
(162 Değerlendirme)
7.5
contriverz

Hi there , Hope you doing great !!! Your given requirements review out very well and its should be performed out accordingly with topmost skills. My $kype contriverz1988 I am a full stack developer and having expe Daha Fazla

£200 GBP in 2 gün içinde
(104 Değerlendirme)
7.6
JinDongZhe

Dear Manager. How do you do? i read your project carefully. I`m interested to work with you!! I have rich experience in web development and mobile . I think your project is adaptable for me. My goal will always be t Daha Fazla

1 gün içinde %bids___i_sum_sub_32%%project_currencyDetails_sign_sub_33% GBP
(102 Değerlendirme)
7.4
ITPyramid85

1. [login to view URL] [Magento] 2. [login to view URL] [Magento] 3. [login to view URL] [Core PHP] 4. [login to view URL] [Directory Listing] 5. [login to view URL] [Opencart] 6. http:// Daha Fazla

£150 GBP in 7 gün içinde
(25 Değerlendirme)
6.9
perlomonster

Hi there! I've noticed you are looking for a dev to optimise your PHP script. Being currently available and having the required experience (6+years), I may prove to be an asset for you. I have a good command of PHP, La Daha Fazla

£250 GBP in 8 gün içinde
(64 Değerlendirme)
6.6
aftabyounas

Hi, I have read your project description and willing to do this for you in your required time spam with 100% Satisfaction. Kindly message me so we can discuss in detail over chat......

£50 GBP in 2 gün içinde
(129 Değerlendirme)
6.5
schoudhary1553

Hello, I have gone through your job posting and become very much interested to work with you. I am an expert in this field. I have already completed several projects like this. For evidence you can see my profile. Pl Daha Fazla

£220 GBP in 4 gün içinde
(72 Değerlendirme)
6.4
nisharapath

Dear employer! Thanks your your job posting. I read your project and I am interested in this field. As you can see my profile, I have rich experiences in PHP. If you hire me, I will do my best and you will see successf Daha Fazla

£135 GBP in 7 gün içinde
(39 Değerlendirme)
6.0
jarki2017

Hello There is one way to resolve this issue. I am specializing in PHP for 14+ years. We can resolve this script with pararel method. Please ping me if you are interested in my proposal. Thanks

£500 GBP in 7 gün içinde
(46 Değerlendirme)
6.1
Alimughal786

Hi Sir, I have reviewed your job description as well & very confident to handle this project perfectly. I'm confident you will be happy with my job.I always have a clear focus on delivering results. I am expert in Web Daha Fazla

£45 GBP in 7 gün içinde
(70 Değerlendirme)
6.2
durgesh8527

Hello Sir/Mam, I have read your post requirement for the " have a php code which is working perfectly but sometimes it takes too long to execute". Now I have some questions to clear the things for this project. I am fu Daha Fazla

£100 GBP in 7 gün içinde
(89 Değerlendirme)
6.5
techplusintl

Hi there, Greetings from TechPlus! I've reviewed your requirements & ready to speed up php script. 5+ Years Expertise in : CMS (Wordpress, Magento, Shopify, OpenCart, Joomla, Drupal, Prestashop) PHP Frameworks (Lara Daha Fazla

£150 GBP in 2 gün içinde
(111 Değerlendirme)
6.3
indiainfosoft

Dear Employer, This is Ajay here. I've reviewed your requirement and I'm ready to work with you. I will provide quality work as well full support for any query. I'm giving you trust for good quality work. I have almo Daha Fazla

1 gün içinde %bids___i_sum_sub_32%%project_currencyDetails_sign_sub_33% GBP
(201 Değerlendirme)
6.5
vranjan

Hi, My work experience as shown in my profile have helped me develop mastery in Website design & development. I'm a full-stack developer with more than 10 years of work experience. Expert in BOTH Backend and Front- Daha Fazla

£135 GBP in 7 gün içinde
(197 Değerlendirme)
7.0
suryabeniwal

Dear Hiring Manager, I can help you in the project. Please let me know when we can discuss in more details so that we could proceed further. Looking forward for your response. Thanks. Kind Regards, Surya

£135 GBP in 7 gün içinde
(46 Değerlendirme)
6.8
brendanmullan90

Hello, my name is Brendan. I have read your project specifications and this job fits within my area of expertise. I would love to come on board and work on this with you. I am available to begin immediately. Relevant Daha Fazla

1 gün içinde %bids___i_sum_sub_32%%project_currencyDetails_sign_sub_33% GBP
(68 Değerlendirme)
6.2
hanchenglu

Hi I'm an old hand in PHP, HTML, Javascript, and MySql and I think I'm a good fit for this project. I can start right away and finish fast. We can have a long relationship. Thanks

£135 GBP in 7 gün içinde
(38 Değerlendirme)
5.9
rylkov

I have experience with slow PHP scripts. Usually I add JavaScript on client side and it run server PHP scripts by parts, shows the progress, calculated results, user can cancel script if he don't want to wait more. Thi Daha Fazla

£120 GBP in 7 gün içinde
(85 Değerlendirme)
5.8
greenforest0204

Hello i am very interested in your post project since i have rich experience on this kind of project. Actually, i am feeling confident about to give you perfect result in time. please call me Dmitrii. looking forward t Daha Fazla

£135 GBP in 7 gün içinde
(54 Değerlendirme)
6.0
hengzhulu

Hello sir. I am very interesting in your project and am glad to bid on your project. I have read your requirements very carefully and understood want do you want. It is very easy for me. If you hire me, i should provid Daha Fazla

£120 GBP in 2 gün içinde
(17 Değerlendirme)
5.6