4 Topics

Member Avatar for
Member Avatar for showman13

OK, I have the following regulare expression for phone number validation, but it doesn't really do EXACTLY what I want... What I want to see is a forced format 000-000-0000 where it needs to be entered with the area code-prefix-suffix including the dashes. I store it in a varchar field …

Member Avatar for AndrisP
0
764
Member Avatar for jonow

Is it possible to remove the suffix of URLs using the .htaccess file? For example you have [url]http://www.example.com/page.php[/url] can you change it to [url]http://www.example.com/page[/url] without the .php. I want it to work both ways, with the .php and without. Is there a way to do it with the .htaccess file? …

Member Avatar for shophiarajan47
0
890
Member Avatar for Kristian_2

I have solved it... Shame... -------------------------------- I have problem with this code: cin >> str; smatch m; regex e("([[:w:]]+)@([[:w:]]+)\.com"); //<- Here was the error (it was regex e("([[:w:]+)@([[:w:]]+)\.com");) silly me :(( bool found = regex_search(str, m, e); cout << "m.size() " << m.size() << endl; for (int n = 0; …

0
146
Member Avatar for nitin1

#include<iostream> #include<algorithm> using namespace std; #define MAX 10000000 #include<stdlib.h> #include<string.h> char s[MAX]; int p[MAX]; int bucket[MAX],nbucket[MAX]; struct suffix { int idx; }pos[MAX]; int H=0; bool cmp(struct suffix i,struct suffix j) { if(H==0) { return s[i.idx]<s[j.idx]; } else { if(bucket[i.idx]==bucket[j.idx]) { return bucket[i.idx+H]<bucket[j.idx+H]; } else { return bucket[i.idx]<bucket[j.idx]; } } } …

Member Avatar for deceptikon
0
610

The End.