A serious problem limiting the applicability of the fuzzy neural networks is the "curse of dimensionality", especially for general continuous functions. A way to deal with this problem is to construct a dynamic hierarchical fuzzy neural network. In this paper, we propose a two-stage genetic algorithm to intelligently construct the dynamic hierarchical fuzzy neural network (HFNN) based on the merged-FNN for general continuous functions. First, we use a genetic algorithm which is popular for flowshop scheduling problems (GA_FSP) to construct the HFNN. Then, a reduced-form genetic algorithm (RGA) optimizes the HFNN constructed by GA_FSP. For a real-world application, the presented method is used to approximate the Taiwanese stock market.