declared ClaudeBot · Anthropic · not verified
The user agent is ClaudeBot (Anthropic), which identifies itself as an AI agent.
Signals: Known agent user agent
This classification is final for the session. The human pages are not served to agents.
{
"question": {
"slug": "subscriber-churn-query",
"title": "Subscriber Churn Query",
"difficulty": "medium",
"tags": [
"sql",
"data",
"technical",
"data-eng"
],
"is_free": true,
"locked": false,
"frequency": 0.75,
"last_reported_at": "2026-07-17T16:54:46.104500Z",
"url": "https://www.mokabla.com/en/c/orange/subscriber-churn-query",
"agent": {
"page": "https://www.mokabla.com/agent/en/c/orange/subscriber-churn-query",
"question": "https://www.mokabla.com/agent/_call/get_question?company=orange&question=subscriber-churn-query"
},
"company": {
"slug": "orange",
"name_en": "Orange Egypt / Orange Business"
},
"body_md": "## Problem\nTwo tables from the billing warehouse:\n\n- `subscribers(msisdn, plan, activated_on)`\n- `monthly_usage(msisdn, month, data_mb, voice_min)`, one row per subscriber per month **only if** they used anything\n\nDefine a subscriber as **churned in month M** if they had a usage row in month M-1 but none in M. Write a query that returns, for each month of 2026 up to June, the number of churned subscribers and the churn rate as a percentage of the previous month's active subscribers, rounded to two decimals.\n\n## Examples\n**Example 1**\nJanuary has 4 active subscribers; in February three of them have usage rows and one does not. February row: `2026-02, 1, 25.00`.\n\n**Example 2**\nA subscriber active in January, absent in February, back in March. They count as churned in February and as active again in March, but they must **not** count as churned in March.\n\n## Constraints\n- `month` is stored as `'YYYY-MM'` text\n- Standard SQL (window functions and CTEs allowed, SQLite-compatible preferred)\n- Months where nobody churned should still appear with 0 and 0.00\n\n## What they look for\nA self-join or `LEFT JOIN` between month M-1 and M on `msisdn` with a NULL check, a months spine so empty months appear, and correct rate denominators. The month-arithmetic on a text column is the practical annoyance they want you to handle cleanly.",
"follow_ups_md": "- Extend the definition to 'no usage for two consecutive months'.\n- How would you attribute churn to a plan?\n- The table has 30M rows per month; what does the plan look like and what index helps?"
},
"paid": false,
"access": "Question bodies are paid content: a person buys 30 days of access per company (200 EGP or 200 points) in the human app. Agents get titles, tags and difficulty; bodies only for free questions."
}
| action | input | permission | |
|---|---|---|---|
| get_question One question with its body. Bodies are paid content unless the question is free. | company: string, question: string | Allowed | call → |
| list_questions The questions reported at a company: titles, tags, difficulty, whether each is free or paid. | company: string, page: number? | Allowed | call → |
| buy_access Buy 30 days of access to a company. | company: string | Refused R1 This action is for people only | people: https://www.mokabla.com/en/pricing |
| post_comment Comment on a question. | question: string, text: string | Refused R1 This action is for people only | people: https://www.mokabla.com/en/companies |
Allowed actions answer in JSON. Add ?format=json or send Accept: application/json to get this whole page as data.