You are not logged in. Please login at www.codechef.com to post your questions!

×

EXPTREE: How to calculate P????

How to calculate P in this question???. I dont Understand Editorial. Please Help me.

Problem

Editorial

asked 17 Jul '17, 20:06

jaypatel3998's gravatar image

3★jaypatel3998
414
accept rate: 0%


Go through this article http://www.cs.tau.ac.il/~nachumd/papers/Enumerations.pdf. Link by @ruskinmanku in EXPTREE Editorial Section.

link

answered 17 Jul '17, 22:34

ashcode0605's gravatar image

5★ashcode0605
312
accept rate: 0%

edited 17 Jul '17, 22:36

This question is all about searching(According to me ). The link above takes you to some papers which has pre-calculated formulas. The no. of vertices which have d(for this d=1) childeren is (2n-1-d)!/((n-1)!(n-d)!). The no. of total possible trees is (2n)!/((n!n!)*(n+1)).Where 'n' is no. of edges . Apply the formula and get the answer. For the modulo inverse http://www.geeksforgeeks.org/multiplicative-inverse-under-modulo-m/ .Hope this help.

link

answered 17 Jul '17, 23:15

g_o_d's gravatar image

4★g_o_d
413
accept rate: 0%

Well getting a formal proof is something really hard, you will find yourself ending in reading papers. My solution was the easiest thing that came up to my mind. Anyway, this solution is kind of intuitive :)

link

answered 18 Jul '17, 08:07

deadwing97's gravatar image

3★deadwing97
108930
accept rate: 0%

I have added small extra explanation in the editorial and also a note which tells the purpose of the editorial

link

answered 18 Jul '17, 09:30

deadwing97's gravatar image

3★deadwing97
108930
accept rate: 0%

toggle preview
Preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported
  • mathemetical formulas in Latex between $ symbol

Question tags:

×229
×22

question asked: 17 Jul '17, 20:06

question was seen: 723 times

last updated: 18 Jul '17, 09:30