WordPress database error: [Table './ay6u3nor6dat6ba1/kn6_ayu1n9k4_5_actionscheduler_actions' is marked as crashed and last (automatic?) repair failed]
SELECT a.action_id FROM kn6_ayu1n9k4_5_actionscheduler_actions a WHERE 1=1 AND a.hook='aioseo_send_usage_data' AND a.status IN ('in-progress') ORDER BY a.scheduled_date_gmt ASC LIMIT 0, 1

WordPress database error: [Table './ay6u3nor6dat6ba1/kn6_ayu1n9k4_5_actionscheduler_actions' is marked as crashed and last (automatic?) repair failed]
SELECT a.action_id FROM kn6_ayu1n9k4_5_actionscheduler_actions a WHERE 1=1 AND a.hook='aioseo_send_usage_data' AND a.status IN ('pending') ORDER BY a.scheduled_date_gmt ASC LIMIT 0, 1

concat, substring strings | Loop and Break

concat, substring strings

Consider the following example for various operations on strings

#include <string>
#include <iostream>
using namespace std;
int main() 
{
    string s1("this string represents s1");
    string s2("All mangoes are bananas");
    string s3("snow is the purest form of water");
    
    // Copy the first 8 chars from s1 in string s4
    // string s4(<string>, <starting index>, <end index>);
    string s4(s1, 0, 8);
    
    //appending strings
    string s5 = string (s1, 0, 4) + " helllo " +
                 string (s3, 0, 8);
                 
    // finding substring 
    //s3.substr(<from starting index>, <upto index>)
    string s6 = s3.substr(5, 10);
    
    string s7 = s3.substr(1, 5) + s5;
        
    cout << s1 << endl;
    cout << s2 << endl;
    cout << s3 << endl;
    cout << s4 << endl;
    cout << s5 << endl;
    cout << s6 << endl;
    cout << s7 << endl;
    
    getchar();
    return 0;
}
Share

You may also like...