Technion First Year2019-03-26T10:50:38+00:00

Welcome Technion First Year Class of 2019

Using Brosencephalon Effectively for USMLE Studying

By |April 22nd, 2019|Categories: featured, Flashcard Resources, Flashcards, Resource Reviews, USMLE Step 1|Tags: |

6 Tips on Using Anki USMLE Flashcards

By |April 18th, 2019|Categories: featured, Flashcard Resources, Flashcards, Resource Reviews, Uncategorized, USMLE Step 1|Tags: , , |

Load More Posts

Common Questions

Have a Question? Please submit it to info@elitemedicalprep.com

Technion 2nd Year Student

Posted: October 9,2018 @4:57 am

Are non-caseating granulomas unique to sarcoidosis? Or do all auto-inflammatory causes of granulomas display non-caseating granulomas? Along the same lines, do all infectious causes of granulomas display caseating granulomas or is it only tuberculosis?

Marcel Brus-Ramer

Technion 2nd Year Student

Are non-caseating granulomas unique to sarcoidosis? Or do all auto-inflammatory causes of granulomas display non-caseating...

Posted: October 18, 2018 @12:00 am


The most common cause of all granuloma formation worldwide is tuberculosis. The formation of granulomas in tuberculosis is thought to be a physiological reaction to prevent the systemic spread of the causative pathogen, the mycobacterium. is immune response typically results in a caseating granuloma with signs of necrosis. Many other infectious agents can trigger granuloma formation as well as foreign body material such as beryllium, and inherited defects in neutrophil function (chronic granulomatous disease). In chronic inflammatory diseases and primary immunodeficiencies with chronic inflammation, the granulomas have not been associated with specific external agents. With the exception of granulomatosis with polyangiitis, these granulomas are non-caseating and typically observed in patients with sarcoidosis, Crohn’s disease and common variable immunodeficiency. Sarcoidosis remains a diagnosis of exclusion

Usmle step 1, Tuberculosis, Sarcoidosis, Granulomas

Technion 2nd Year Student

Posted: August 14,2018 @4:57 am

I am going into my second year in Technion Medical School. You mentioned that we should use our vacation to make a study schedule; I was wondering how to go about making one? Which subjects should I focus on and when? Should I just go through First Aid by subject? How much time should I spend on each subject?

Ken Rubin, MD

Technion 2nd Year Student

I am going into my second year in Technion Medical School. You mentioned that we should use our vacation to make a study...

Posted: August 15, 2018 @7:21 am


We would recommend quality over quantity for UW review. Certain weeks will be busier for you depending on when you have exams and other commitments. Aim for a number of questions per day (or per week) that allows you to review each one thoroughly without feeling rushed for time. Also understand that there will be certain days when you won't make qbank progress. You may want to work in a few “OFF” days to account for this. Consistency is also important. You want to feel like you can make steady progress throughout the year without having a wide open schedule, because you will never have a wide open schedule. You may also want to track the questions you complete. The qbank software tracks for you, but you can use a notebook and write down every night you complete a set, including the topic and number of questions. This can help keep you on track and create a system of structure and accountability. I can't comment for sure on what percentage of the material you've learned during 1st year, although 5% seems low. It is important to complete questions in areas you have covered. For example, it is not helpful to do heme questions if you haven't learned heme yet.

Study schedule, First Aid

Technion 2nd Year Student

Posted: July 19,2018 @4:57 am

3 day old boy brought to the ER due to poor feeding, emesis and lethargy over the last 24 hrs. Patient was born via uncomplicated spontaneous vaginal delivery to a 30 yo. Boy was discharged from nursery and was breastfeeding exclusively until the onset of the symptoms. stool and urine output were normal while he was in the nursery. Patient is afebrile and normotensive but tachycardic and tachypneic. He appears dehydrated and the abdomen is distended. patients vomits during examination (green). On laparotomy fibrous bands are seen extending from the cecum and right colon to the retroperitoneum causing extrinsic compression of the duodenum. Which of the following embryologic processes most likely failed in this patient?

Martin B. MD

Technion 2nd Year Student

3 day old boy brought to the ER due to poor feeding, emesis and lethargy over the last 24 hrs. Patient was born via uncomplicated...

Posted: July 20, 2018 @4:40 pm


This newborn patient also has an SBO due to fibrotic strictures suggesting a severe congenital anatomical anomaly. They are vomiting with a distended bowel due to the sbo just like in question 1. Given we suspect a congenital anomaly where the bowel is tied down (and therefore can’t rotate), malrotation would fit both as the cause of the sbo, the age of the patient, and a result of the fibrous banding. So in sum, sbos are significant with vomiting and distension. Meckel's is very benign and usually presents incidentally (as in this question) or with mild melena that would prompt a tech-99 scan in a newborn, but does not BY ITSELF cause an SBO.

Malrotation, Extrinsic compression, Embryologic processes

Technion 2nd Year Student

Posted: July 7,2018 @4:57 am

I can’t figure out this question: 1) 2 y.o. boy brought to the ER after develops acute abdominal pain and vomiting. imaging studies reveal a foreign body lodged within his intestine causing a small bowel obstruction. laparotomy is performed to remove the foreign body; during the procedure an incidental abdominal cyst is discovered and removed. The cyst is connected by a fibrous band to the ileum and the umbilicus. Which of the following conditions is also caused by the same embryological defect responsible for this patient’s abdominal cyst?

Martin B. MD

Technion 2nd Year Student

I can’t figure out this question: 1) 2 y.o. boy brought to the ER after develops acute abdominal pain and vomiting....

Posted: July 8, 2018 @1:07 pm


This patient has an SBO due to foreign body and then has meckles discovered incidentally on surgical exploration. As discussed, a Meckel's is a rather benign entity that causes little more than mild bleeding and an occasional intussusception if it serves as a lead point.  So again, they just happen to see this meckles when digging around in the bowel. The patients vomiting is related to their SBO, which is due to the foreign body, not the incidental Meckel's. The description of the incidental finding is also classic for what a Meckel's is: a band of tissue connecting the small bowel to the umbilicus. The age of the patient is also classic.

Meckel, Laparotomy, Embryological defect

Technion 2nd Year Student

Posted: July 3,2018 @4:57 am

I am having trouble understanding how to diagnose meckel diverticulum verse malrotation. Both disorders present with fibrous bands and vomiting. The u-world question ID numbers are 322 and 318. Would you be able to explain how to distinguish the two?

Martin B. MD

Technion 2nd Year Student

I am having trouble understanding how to diagnose meckel diverticulum verse malrotation. Both disorders present with fibrous...

Posted: July 4, 2018 @11:29 am


At a high level key differences you should look for include: -Malro causes more classic and severe SBO (persistent distention, fullness, pain) whereas meckles does not unless a concomitant intususception has occurred in which case you’ll see colicky pain with less distension given the relapsing remitting course. -Malro will be diagnosed with a barium study and small bowel follow through whereas meckles will show focal uptake on a technicium 99 scan -Meckles can present with isolated blood whereas malro you’d only see blood in a well entrenched SBO, so there’s a disease severity and time course component here that could be in the prompt.

Uworld, Meckel, Malrotation, Diverticulum

Technion 2nd Year Student

Posted: April 18,2018 @4:57 am

I have a question regarding how I should spend my last month studying. My exam is May 18. I have about 300 Uworld questions left before i finish my first pass through (64% correct, 225 on my last nbme). I started doing questions on Uworld probably 6 months ago. I have ~700 incorrect questions, and ~300 marked. Does it make more sense to spend the month redoing those questions and studying them, or should I just restart my Uworld and try to get through everything again in this one month? I don’t see myself getting through more than 80 questions a day, I still am going through pathoma for a few hours every day too. Any advice would be appreciated.

Marcel Brus-Ramer, MD

Technion 2nd Year Student

I have a question regarding how I should spend my last month studying. My exam is May 18. I have about 300 Uworld questions...

Posted: April 19, 2018 @7:42 am


To summarize, you have max 1000 questions that you'd like to see again and you have about 30 days left. In my opinion, I would try to get through a large chunk of the questions you got wrong and finish up your first pass of UWorld. Try to increase your daily question volume to 90 or 100 per day. I would intersperse the two question types so as to complete this first pass and then leave yourself without 3 weeks to start working through the Q Bank again. Keep in mind that reviewing wrong answers,  and the 2nd pass of the Q Bank, should be faster than the first pass. However don't just super speed through as many questions as possible on the second pass just to say you did them all twice. Quality review is still important, esp on questions where greater than 50% of respondents got the question right. As you approach test day it may be worth decreasing the time on Pathoma and putting more effort into questions and Flashcards.

Tips, Studying, Study schedule, Last month

Technion 2nd Year Student

Posted: April 17,2018 @4:57 am

I just completed NBME 15 and have a question that I can’t quite figure out by myself. I was wondering if you could provide me with some explanations. I was wondering, is the bleeding stopped by the oxytocin induced contraction of the uterine tissue? Or is it a different mechanism?

Here’s the initial question: One-half hour after an uncomplicated vaginal delivery, a 30-year-old woman delivers the placenta but has continued heave blood loss from the vagina. Her pulse is 120/min, and blood pressure is 90/60 mm Hg. No cervical or perineal lacerations are noted. The uterus is soft, and contractions have stopped. Medical treatment with which of the following agents is likely to be most helpful? Androgen, Estrogen, Progesterone, Prolactin or Oxytocin

Abigail Garbarino, MD

Technion 2nd Year Student

I just completed NBME 15 and have a question that I can’t quite figure out by myself. I was wondering if you could provide...

Posted: April 18, 2018 @11:34 pm


Yes oxytocin release is the body's natural way of "clamping down" the uterus after birth. You will see pitocin (formulated oxytocin) given almost immediately after given to help speed this along. Baby is also put on the breast to stimulate oxytocin release.  The most common cause of uterine atony is retained products of conception (POCs), and it should be confirmed that all of the placenta has been delivered. Oxytocin is a common drug (and endogenous pituitary hormone) used to both induce uterine contractions during labor and to induce the contraction of the uterus post-partum in cases of uterine atony. Prolactin is a hormone that causes breast milk production endogenously.

NBME 15

Technion First Year Class of 2019

TOPIC SEARCH

Technion 2nd Year Student
Posted:October 9,2018 @4:57 am

Are non-caseating granulomas unique to sarcoidosis? Or do all auto-inflammatory causes of granulomas display non-caseating granulomas? Along the same lines, do all infectious causes of granulomas display caseating granulomas or is it only tuberculosis?

Marcel Brus-Ramer
Posted: October 18, 2018 @12:00 am
Technion 2nd Year Student

Are non-caseating granulomas unique to sarcoidosis? Or do all auto-inflammatory causes of...

The most common cause of all granuloma formation worldwide is tuberculosis. The formation of granulomas in tuberculosis is thought to be a physiological reaction to prevent the systemic spread of the causative pathogen, the mycobacterium. is immune response typically results in a caseating granuloma with signs of necrosis. Many other infectious agents can trigger granuloma formation as well as foreign body material such as beryllium, and inherited defects in neutrophil function (chronic granulomatous disease). In chronic inflammatory diseases and primary immunodeficiencies with chronic inflammation, the granulomas have not been associated with specific external agents. With the exception of granulomatosis with polyangiitis, these granulomas are non-caseating and typically observed in patients with sarcoidosis, Crohn’s disease and common variable immunodeficiency. Sarcoidosis remains a diagnosis of exclusion

Usmle step 1, Tuberculosis, Sarcoidosis, Granulomas

Technion 2nd Year Student
Posted:August 14,2018 @4:57 am

I am going into my second year in Technion Medical School. You mentioned that we should use our vacation to make a study schedule; I was wondering how to go about making one? Which subjects should I focus on and when? Should I just go through First Aid by subject? How much time should I spend on each subject?

Ken Rubin, MD
Posted: August 15, 2018 @7:21 am
Technion 2nd Year Student

I am going into my second year in Technion Medical School. You mentioned that we should...

We would recommend quality over quantity for UW review. Certain weeks will be busier for you depending on when you have exams and other commitments. Aim for a number of questions per day (or per week) that allows you to review each one thoroughly without feeling rushed for time. Also understand that there will be certain days when you won't make qbank progress. You may want to work in a few “OFF” days to account for this. Consistency is also important. You want to feel like you can make steady progress throughout the year without having a wide open schedule, because you will never have a wide open schedule. You may also want to track the questions you complete. The qbank software tracks for you, but you can use a notebook and write down every night you complete a set, including the topic and number of questions. This can help keep you on track and create a system of structure and accountability. I can't comment for sure on what percentage of the material you've learned during 1st year, although 5% seems low. It is important to complete questions in areas you have covered. For example, it is not helpful to do heme questions if you haven't learned heme yet.

Study schedule, First Aid

Technion 2nd Year Student
Posted:July 19,2018 @4:57 am

3 day old boy brought to the ER due to poor feeding, emesis and lethargy over the last 24 hrs. Patient was born via uncomplicated spontaneous vaginal delivery to a 30 yo. Boy was discharged from nursery and was breastfeeding exclusively until the onset of the symptoms. stool and urine output were normal while he was in the nursery. Patient is afebrile and normotensive but tachycardic and tachypneic. He appears dehydrated and the abdomen is distended. patients vomits during examination (green). On laparotomy fibrous bands are seen extending from the cecum and right colon to the retroperitoneum causing extrinsic compression of the duodenum. Which of the following embryologic processes most likely failed in this patient?

Martin B. MD
Posted: July 20, 2018 @4:40 pm
Technion 2nd Year Student

3 day old boy brought to the ER due to poor feeding, emesis and lethargy over the last 24...

This newborn patient also has an SBO due to fibrotic strictures suggesting a severe congenital anatomical anomaly. They are vomiting with a distended bowel due to the sbo just like in question 1. Given we suspect a congenital anomaly where the bowel is tied down (and therefore can’t rotate), malrotation would fit both as the cause of the sbo, the age of the patient, and a result of the fibrous banding. So in sum, sbos are significant with vomiting and distension. Meckel's is very benign and usually presents incidentally (as in this question) or with mild melena that would prompt a tech-99 scan in a newborn, but does not BY ITSELF cause an SBO.

Malrotation, Extrinsic compression, Embryologic processes

Technion 2nd Year Student
Posted:July 7,2018 @4:57 am

I can’t figure out this question: 1) 2 y.o. boy brought to the ER after develops acute abdominal pain and vomiting. imaging studies reveal a foreign body lodged within his intestine causing a small bowel obstruction. laparotomy is performed to remove the foreign body; during the procedure an incidental abdominal cyst is discovered and removed. The cyst is connected by a fibrous band to the ileum and the umbilicus. Which of the following conditions is also caused by the same embryological defect responsible for this patient’s abdominal cyst?

Martin B. MD
Posted: July 8, 2018 @1:07 pm
Technion 2nd Year Student

I can’t figure out this question: 1) 2 y.o. boy brought to the ER after develops acute...

This patient has an SBO due to foreign body and then has meckles discovered incidentally on surgical exploration. As discussed, a Meckel's is a rather benign entity that causes little more than mild bleeding and an occasional intussusception if it serves as a lead point.  So again, they just happen to see this meckles when digging around in the bowel. The patients vomiting is related to their SBO, which is due to the foreign body, not the incidental Meckel's. The description of the incidental finding is also classic for what a Meckel's is: a band of tissue connecting the small bowel to the umbilicus. The age of the patient is also classic.

Meckel, Laparotomy, Embryological defect

Technion 2nd Year Student
Posted:July 3,2018 @4:57 am

I am having trouble understanding how to diagnose meckel diverticulum verse malrotation. Both disorders present with fibrous bands and vomiting. The u-world question ID numbers are 322 and 318. Would you be able to explain how to distinguish the two?

Martin B. MD
Posted: July 4, 2018 @11:29 am
Technion 2nd Year Student

I am having trouble understanding how to diagnose meckel diverticulum verse malrotation....

At a high level key differences you should look for include: -Malro causes more classic and severe SBO (persistent distention, fullness, pain) whereas meckles does not unless a concomitant intususception has occurred in which case you’ll see colicky pain with less distension given the relapsing remitting course. -Malro will be diagnosed with a barium study and small bowel follow through whereas meckles will show focal uptake on a technicium 99 scan -Meckles can present with isolated blood whereas malro you’d only see blood in a well entrenched SBO, so there’s a disease severity and time course component here that could be in the prompt.

Uworld, Meckel, Malrotation, Diverticulum

Technion 2nd Year Student
Posted:April 18,2018 @4:57 am

I have a question regarding how I should spend my last month studying. My exam is May 18. I have about 300 Uworld questions left before i finish my first pass through (64% correct, 225 on my last nbme). I started doing questions on Uworld probably 6 months ago. I have ~700 incorrect questions, and ~300 marked. Does it make more sense to spend the month redoing those questions and studying them, or should I just restart my Uworld and try to get through everything again in this one month? I don’t see myself getting through more than 80 questions a day, I still am going through pathoma for a few hours every day too. Any advice would be appreciated.

Marcel Brus-Ramer, MD
Posted: April 19, 2018 @7:42 am
Technion 2nd Year Student

I have a question regarding how I should spend my last month studying. My exam is May 18....

To summarize, you have max 1000 questions that you'd like to see again and you have about 30 days left. In my opinion, I would try to get through a large chunk of the questions you got wrong and finish up your first pass of UWorld. Try to increase your daily question volume to 90 or 100 per day. I would intersperse the two question types so as to complete this first pass and then leave yourself without 3 weeks to start working through the Q Bank again. Keep in mind that reviewing wrong answers,  and the 2nd pass of the Q Bank, should be faster than the first pass. However don't just super speed through as many questions as possible on the second pass just to say you did them all twice. Quality review is still important, esp on questions where greater than 50% of respondents got the question right. As you approach test day it may be worth decreasing the time on Pathoma and putting more effort into questions and Flashcards.

Tips, Studying, Study schedule, Last month

Technion 2nd Year Student
Posted:April 17,2018 @4:57 am

I just completed NBME 15 and have a question that I can’t quite figure out by myself. I was wondering if you could provide me with some explanations. I was wondering, is the bleeding stopped by the oxytocin induced contraction of the uterine tissue? Or is it a different mechanism?

Here’s the initial question: One-half hour after an uncomplicated vaginal delivery, a 30-year-old woman delivers the placenta but has continued heave blood loss from the vagina. Her pulse is 120/min, and blood pressure is 90/60 mm Hg. No cervical or perineal lacerations are noted. The uterus is soft, and contractions have stopped. Medical treatment with which of the following agents is likely to be most helpful? Androgen, Estrogen, Progesterone, Prolactin or Oxytocin

Abigail Garbarino, MD
Posted: April 18, 2018 @11:34 pm
Technion 2nd Year Student

I just completed NBME 15 and have a question that I can’t quite figure out by myself....

Yes oxytocin release is the body's natural way of "clamping down" the uterus after birth. You will see pitocin (formulated oxytocin) given almost immediately after given to help speed this along. Baby is also put on the breast to stimulate oxytocin release.  The most common cause of uterine atony is retained products of conception (POCs), and it should be confirmed that all of the placenta has been delivered. Oxytocin is a common drug (and endogenous pituitary hormone) used to both induce uterine contractions during labor and to induce the contraction of the uterus post-partum in cases of uterine atony. Prolactin is a hormone that causes breast milk production endogenously.

NBME 15

Welcome First Year Class of 2019!

On this page, you will find links to:
– Webinar registration for each lecture
– Lecture recordings
– Associated lecture notes
Please send questions, comments, and concerns to:
technion2021@elitemedicalprep.com

Lecture 2.1

Delivered on:

October. 29, 2018

Lecture 2.2

Scheduled for:

January 2018

Download Lecture 2.1 Slides PDF
Class Calendar–In Development

UWorld vs. TrueLearn

By |November 21st, 2019|Categories: Resource Reviews, USMLE Step 1|Tags: , , |

Move over UWorld! There's a new qbank in town! Is there a new contender for the qbank throne? Here's our honest reviewal of the TrueLearn question bank and how it stacks up next to UWorld.

Using Brosencephalon Effectively for USMLE Studying

By |April 22nd, 2019|Categories: featured, Flashcard Resources, Flashcards, Resource Reviews, USMLE Step 1|Tags: |

If you haven't already heard of the Brosencephalon (Bros) deck, it's time to get acquainted! Bros is one of several popular pre-made flashcard decks

6 Tips on Using Anki USMLE Flashcards

By |April 18th, 2019|Categories: featured, Flashcard Resources, Flashcards, Resource Reviews, Uncategorized, USMLE Step 1|Tags: , , |

When it comes to studying for the USMLE, it’s worth learning how to make proper flashcards up front. While there are many different USMLE..

Load More Posts
[fusion_code]PHNjcmlwdCB0eXBlPSJ0ZXh0L2phdmFzY3JpcHQiPgoKCiAgICAkKGZ1bmN0aW9uICgpIHsKICAgICAgICAkKCIuY29udGVudCIpLnNsaWNlKDAsIDApLnNob3coKTsKICAgICAgICAkKCIubG9hZE1vcmUiKS5vbignY2xpY2snLCBmdW5jdGlvbiAoZSkgewogICAgICAgICAgICBlLnByZXZlbnREZWZhdWx0KCk7CiAgICAgICAgICAgICQoIi5jb250ZW50OmhpZGRlbiIpLnNsaWNlKDAsIDMpLnNsaWRlRG93bigpOwogICAgICAgICAgICBpZiAoJCgiLmNvbnRlbnQ6aGlkZGVuIikubGVuZ3RoID09IDApIHsKCiAgICAgICAgICAgICAgICAkKCIjbG9hZCIpLmZhZGVPdXQoJ3Nsb3cnKTsKICAgICAgICAgICAgICAgICQoIi5sb2FkTW9yZSIpLmNzcygiZGlzcGxheSIsJ25vbmUnKTsKCgogICAgICAgICAgICAgICAgJCgiLnBvc3Rtc2d0eHQiKS5jc3MoImRpc3BsYXkiLCJibG9jayIpLmZhZGVPdXQoMzAwMCk7CiAgICAgICAgICAgICAvLyAkKCIucmVhZG1vcmUiKS5odG1sKCc8cCBzdHlsZT0iY29sb3I6I2JiMTkyOCI+QWxsIFBvc3RzIGRpc3BsYXllZDwvcD4nKS5mYWRlT3V0KDMwMDApOwogICAgICAgICB9CgogICAgICAgICAkKCdodG1sLGJvZHknKS5hbmltYXRlKHsKCi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gInllbGxvdyIgKTsKCiAgICAvLyAgICAgICAgICAgICAgICAgICAgIHsKICAgIC8vICAgICAgICAgICAgICAgICAgICAgICAgIGNvbnNvbGUubG9nKCJGZGZkIik7CiAgICAgICAgICAgICAgICAgICAgICAgICAgIC8vICQoJy5sb2FkTW9yZTEnKS5jc3MoImRpc3BsYXkiLCJibG9jayIpOwogICAgICAgICAgICAvLyAkKCcudHh0bm90Zm91bmQnKS5jc3MoImRpc3BsYXkiLCJibG9jayIpOwoKICAgIC8vICAgICAgICAgICAgICAgICAgICAgfQogICAgCn0KCgogICAvLyBpZigkKCIuZGlzZWFzZXN0YWdzOmNvbnRhaW5zKCIrc2VhcmNoVGVybSsiKSIpLmxlbmd0aCAhPSAxKQogICAvLyB7CiAgIC8vICAgICAkKCcubG9hZE1vcmUxJykuY3NzKCJkaXNwbGF5Iiwibm9uZSIpOwogICAvLyAgICAgICAgICAkKCcudHh0bm90Zm91bmQnKS5jc3MoImRpc3BsYXkiLCJibG9jayIpOwogICAvLyB9CgoKCn0pOwogICAgfSkKCn0pOwoKCiQoIi5jbGVhcmFibGUiKS5lYWNoKGZ1bmN0aW9uKCkgewogICAgdmFyICRpbnAgPSAkKHRoaXMpLmZpbmQoImlucHV0OnRleHQiKSwKICAgICRjbGUgPSAkKHRoaXMpLmZpbmQoIi5jbGVhcmFibGVfX2NsZWFyIik7CiAgICAkaW5wLm9uKCJpbnB1dCIsIGZ1bmN0aW9uKCkgewogICAgICAgICRjbGUudG9nZ2xlKCEhdGhpcy52YWx1ZSk7CiAgICB9KTsKICAgICRjbGUub24oImNsaWNrIiwgZnVuY3Rpb24oZSkgewogICAgICAgIGUucHJldmVudERlZmF1bHQoKTsKICAgICAgICAkaW5wLnZhbCgiIikudHJpZ2dlcigiaW5wdXQiKTsKICAgICAgICAkKCcuc2VhcmNoaWNvbicpLnJlbW92ZUF0dHIoInN0eWxlIik7CiAgICAgICAgJCgnLnRhZ19wJykuc2hvdygpOwogICAgICAgICQoJy5kaXNlYXNlc3RhZ3MnKS5yZW1vdmVIaWdobGlnaHQoKTsKICAgICAgICAkKCcudHh0bm90Zm91bmQnKS5jc3MoImRpc3BsYXkiLCJub25lIik7CiAgICAgICAgJCgnLmxvYWRNb3JlMScpLmNzcygiZGlzcGxheSIsImJsb2NrIik7CiAgICB9KTsKICAgICQoJ2lucHV0W3R5cGU9InRleHQiXScpLm9uKCdmb2N1cycsIGZ1bmN0aW9uKCkgewogICAgICAgICQoJy5zZWFyY2hpY29uJykuY3NzKCJkaXNwbGF5IiwgIm5vbmUiKTsKICAgIH0pOwp9KTsKCgo8L3NjcmlwdD4KCgo=[/fusion_code]